Check .net version powershell

broken image
broken image

If ((Get-ItemProperty -Path 'HKLM:\Software\Microsoft\NET Framework Setup\NDP\v4\Full' -ErrorAction Silentl圜ontinue).Version -ge '4.6.1') You can modify as needed to fit your own needs. NET version, if it is not at a minimum 4.6.1 then depending on if the Windows Server is 2008/2012 or 2016 then version 4.6.2/4.7.1 respectively will be downloaded and installed. This function will check the currently installed.