{"id":76820,"date":"2024-10-19T19:11:23","date_gmt":"2024-10-19T13:41:23","guid":{"rendered":"http:\/\/198.58.113.91\/blog\/?p=76820"},"modified":"2024-10-19T19:15:02","modified_gmt":"2024-10-19T13:45:02","slug":"powershell-error-v4-net-framework-not-installed","status":"publish","type":"post","link":"https:\/\/www.winhelponline.com\/blog\/powershell-error-v4-net-framework-not-installed\/","title":{"rendered":"PowerShell: Version v4.0.30319 of the .NET Framework is not installed"},"content":{"rendered":"<p>When you open Windows Terminal (PowerShell), the following error may occur:<\/p>\n<pre class=\"err\">Version v4.0.30319 of the .NET Framework is not installed and it is required to run version 3 of Windows PowerShell.\n<\/pre>\n<p>If you run PowerShell.exe, the window may close immediately.<!--more--><\/p>\n<p>Running the .NET Framework Repair tool or removing and reinstalling .NET Framework may not resolve the error.<\/p>\n<div class=\"rp\"><strong>RELATED:<\/strong> <a href=\"https:\/\/www.winhelponline.com\/blog\/powershell-closes-machine-config-parser-error\/\">PowerShell Closes Immediately When Launched; Machine.Config Parser Error<\/a><\/div>\n<h2>Cause<\/h2>\n<p>The above error occurs due to the missing <strong>InstallRoot<\/strong> registry value in one or both of the following keys:<\/p>\n<pre class=\"registry\">HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\.NETFramework\nHKEY_LOCAL_MACHINE\\SOFTWARE\\WOW6432Node\\Microsoft\\.NETFramework\n<\/pre>\n<div class=\"rp\"><strong>RELATED:<\/strong> <a href=\"https:\/\/www.winhelponline.com\/blog\/internal-powershell-error-80070002\/\">[Fix] Internal Windows PowerShell error 80070002<\/a><\/div>\n<h2>Resolution<\/h2>\n<p>To resolve the PowerShell error, please create the missing values in the registry.<\/p>\n<h3>Option 1: Use the REG file to restore the missing values<\/h3>\n<p>To restore the <strong>InstallRoot<\/strong> registry value, download and run <a href=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/12\/netfx_installroot_fix.zip\">netfx_installroot_fix.reg<\/a> (zipped)<\/p>\n<p>Unzip and run the enclosed REG file.<\/p>\n<p>Click Yes to confirm.<\/p>\n<hr \/>\n<h3>Option 2: Create the values manually<\/h3>\n<ol>\n<li>Launch Regedit.exe and go to:\n<pre class=\"registry\">HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\.NETFramework<\/pre>\n<\/li>\n<li>In the right pane, create a new string value (REG_SZ) named <strong>InstallRoot<\/strong> (if it doesn&#8217;t already exist.)<\/li>\n<li>Set the value data of <strong>InstallRoot<\/strong> to <strong>C:\\Windows\\Microsoft.NET\\Framework64\\<\/strong><br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2024\/10\/installroot_registry_fix.png\" alt=\".net installroot fix - powershell closes\" width=\"700\" height=\"208\" class=\"alignnone size-full wp-image-76821\" \/><\/li>\n<li>Next, go to the following branch:\n<pre class=\"registry\">HKEY_LOCAL_MACHINE\\SOFTWARE\\WOW6432Node\\Microsoft\\.NETFramework<\/pre>\n<\/li>\n<li>In the right pane, create a new string value (REG_SZ) named <strong>InstallRoot<\/strong> (if it doesn&#8217;t already exist.)<\/li>\n<li>Set the value data of <strong>InstallRoot<\/strong> to <strong>C:\\Windows\\Microsoft.NET\\Framework\\<\/strong><\/li>\n<li>Exit the Registry Editor.<\/li>\n<\/ol>\n<p><strong>Note:<\/strong> The 2nd location above (i.e., the WOW6432Node branch) doesn&#8217;t exist in the Windows 10\/11 32-bit edition. In that case, skip the 2nd location. To determine if you&#8217;re using a 32-bit or 64-bit edition, see <a href=\"https:\/\/www.winhelponline.com\/blog\/find-windows-10-build-version-edition-bit\/\">How to Find Your Windows 10\/11 Build Number, Version, Edition, and Bitness<\/a>.<\/p>\n<p>That should resolve the .NET Framework &#8220;Version v4.0.30319 of the .NET Framework is not installed&#8221; error when launching Terminal\/PowerShell.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When you open Windows Terminal (PowerShell), the following error may occur: Version v4.0.30319 of the .NET Framework is not installed and it is required to run version 3 of Windows PowerShell. If you run PowerShell.exe, the window may close immediately.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[8,869],"tags":[191,396],"class_list":["post-76820","post","type-post","status-publish","format-standard","hentry","category-windows-10","category-windows-11","tag-error-messages","tag-powershell"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":55748,"url":"https:\/\/www.winhelponline.com\/blog\/powershell-closes-machine-config-parser-error\/","url_meta":{"origin":76820,"position":0},"title":"PowerShell Closes Immediately When Launched; Machine.Config Parser Error","author":"Ramesh","date":"June 23, 2023","format":false,"excerpt":"When you run PowerShell.exe, the PowerShell window may open and close immediately before you can read the error message. Running PowerShell.exe from an existing Command Prompt window, or opening PowerShell via Windows Terminal may show the error message: The shell cannot be started. A failure occurred during initialization: The type\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"machine.config fix file","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/machine.config_parser_error_fix_cmd.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/machine.config_parser_error_fix_cmd.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/machine.config_parser_error_fix_cmd.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/machine.config_parser_error_fix_cmd.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":79729,"url":"https:\/\/www.winhelponline.com\/blog\/netfx3-update-error-0x800f0922\/","url_meta":{"origin":76820,"position":1},"title":"[Fix] .NET Framework 3.5 Installation Error 0x800F0922","author":"Ramesh","date":"October 30, 2025","format":false,"excerpt":"When you install the latest cumulative update or the .NET Framework 3.5 using OptionalFeatures.exe, the installation may rollback with the error code 0x800F0922. When the latest cumulative update fails, the CBS log may contain the following entry: Error CSI 000001f9 (F) Done with generic command 2; CreateProcess returned 0, CPAW\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":4855,"url":"https:\/\/www.winhelponline.com\/blog\/restore-windows-store-windows-10-uninstall-with-powershell\/","url_meta":{"origin":76820,"position":2},"title":"Restore Microsoft Store in Windows 10\/11 after uninstalling it with PowerShell","author":"Ramesh","date":"December 21, 2016","format":false,"excerpt":"Windows 10 and 11 come with many built-in Store apps that may not be useful to you. As you may have known, PowerShell allows you to uninstall individual apps or all apps using a single command. If you had used the following command to uninstall all bundled apps in Windows\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"Microsoft Store app installer from AppStore.","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/12\/store-installer-appstore.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/12\/store-installer-appstore.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/12\/store-installer-appstore.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/12\/store-installer-appstore.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":26655,"url":"https:\/\/www.winhelponline.com\/blog\/need-new-app-open-windows-defender-link\/","url_meta":{"origin":76820,"position":3},"title":"You&#8217;ll need a new app to open this windowsdefender link","author":"Ramesh","date":"May 9, 2022","format":false,"excerpt":"After installing the Windows 11 Feature Update, you may notice that the Windows Defender Security settings page can't be opened. Nothing may happen when you open the Windows Security dashboard, or the following error may occur when you do so: You'll need a new app to open this windowsdefender link\u2026","rel":"","context":"In &quot;Windows 11&quot;","block_context":{"text":"Windows 11","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-11\/"},"img":{"alt_text":"get an app to open windows defender link","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2022\/05\/get-an-app-defender-link.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":76808,"url":"https:\/\/www.winhelponline.com\/blog\/internal-powershell-error-80070002\/","url_meta":{"origin":76820,"position":4},"title":"[Fix] Internal Windows PowerShell error 80070002","author":"Ramesh","date":"October 18, 2024","format":false,"excerpt":"When you open Windows Terminal (PowerShell), the following error may occur: Internal Windows PowerShell error. Loading managed Windows PowerShell failed with error 80070002. If you run PowerShell.exe, the window may close abruptly. RELATED: PowerShell Closes Immediately When Launched; Machine.Config Parser Error Cause This happens if the file \"Microsoft.PowerShell.ConsoleHost.dll\" is missing\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":34529,"url":"https:\/\/www.winhelponline.com\/blog\/error-itunes-store-installed-users\/","url_meta":{"origin":76820,"position":5},"title":"Error &#8220;One or more users on this computer have installed iTunes&#8221;","author":"Ramesh","date":"March 17, 2023","format":false,"excerpt":"When you install iTunes classic version from the Applet website, the following error may appear: One or more users on this computer have installed iTunes from the Microsoft Store. iTunes may not run correctly after this installation. Do you want to continue? The above error occurs even though you have\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"itunes store version installed error","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/03\/itunes-store-version-conflict.jpg?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/03\/itunes-store-version-conflict.jpg?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/03\/itunes-store-version-conflict.jpg?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/03\/itunes-store-version-conflict.jpg?resize=700%2C400&ssl=1 2x"},"classes":[]}],"_links":{"self":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts\/76820","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/comments?post=76820"}],"version-history":[{"count":0,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts\/76820\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/media?parent=76820"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/categories?post=76820"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/tags?post=76820"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}