{"id":1907,"date":"2021-04-14T18:12:02","date_gmt":"2021-04-14T23:12:02","guid":{"rendered":"http:\/\/montgomeryminds.com\/blog\/?p=1907"},"modified":"2021-04-14T18:14:03","modified_gmt":"2021-04-14T23:14:03","slug":"you-cant-just-copy-notepade-exe-and-run-it-in-windows-10","status":"publish","type":"post","link":"https:\/\/montgomeryminds.com\/blog\/you-cant-just-copy-notepade-exe-and-run-it-in-windows-10\/","title":{"rendered":"You can&#8217;t just copy notepade.exe and run it in Windows 10"},"content":{"rendered":"\n<p>You might think you can just copy <code>notepad.exe<\/code> and run it:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">PS C:\\tmp&gt; copy C:\\windows\\notepad.exe c:\\tmp\nPS C:\\tmp&gt; dir c:\\tmp *\n\nDirectory: C:\\tmp\n\nMode    LastWriteTime       Length  Name\n\u2014a\u2014\u2014\u2014\u2014    2\/20\/2021 11:35 PM  181248  notepad.exe\n\nPS C:\\tmp&gt; .\\notepad.exe\nPS C:\\tmp&gt; # Nothing happens...\n<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_122415_powershell_Windows_PowerShell.png\"><img loading=\"lazy\" width=\"738\" height=\"419\" src=\"https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_122415_powershell_Windows_PowerShell.png\" alt=\"\" class=\"wp-image-1910\" srcset=\"https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_122415_powershell_Windows_PowerShell.png 738w, https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_122415_powershell_Windows_PowerShell-300x170.png 300w, https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_122415_powershell_Windows_PowerShell-500x284.png 500w\" sizes=\"(max-width: 738px) 100vw, 738px\" \/><\/a><\/figure>\n\n\n\n<p>But nothing happens.<\/p>\n\n\n\n<p>What&#8217;s wrong? This is a simple operation!<\/p>\n\n\n\n<h2>Answer: You need the <code>.\\en-US\\notepad.exe.mui<\/code> file<\/h2>\n\n\n\n<p>Or, more generally the <code>.\\xx-YY\\notepad.exe.mui<\/code> file, for any local &#8220;xx-YY&#8221;, for any similar built-in Microsoft\u2122 program.<\/p>\n\n\n\n<p>For <code>notepad.exe<\/code> you can find this file in  <code>c:\\windows\\xx-YY\\notepad.exe.mui<\/code> <\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">PS C:\\tmp&gt; mkdir en-US\n\n\n    Directory: C:\\tmp\n\n\nMode                LastWriteTime         Length Name\n----                -------------         ------ ----\nd-----         4\/2\/2021  11:26 AM                en-US\n\n\nPS C:\\tmp&gt; copy C:\\Windows\\notepad.exe .\\\nPS C:\\tmp&gt; copy C:\\Windows\\en-us\\notepad.exe.mui .\\en-US\\\nPS C:\\tmp&gt; dir\n\n\n    Directory: C:\\tmp\n\n\nMode                LastWriteTime         Length Name\n----                -------------         ------ ----\nd-----         4\/2\/2021  11:27 AM                en-US\n-a----        2\/20\/2021  11:35 PM         181248 notepad.exe\n\n\nPS C:\\tmp&gt; dir .\\en-US\\\n\n\n    Directory: C:\\tmp\\en-US\n\n\nMode                LastWriteTime         Length Name\n----                -------------         ------ ----\n-a----        3\/19\/2019   2:18 AM          12288 notepad.exe.mui\n\n\nPS C:\\tmp&gt; .\\notepad.exe\nPS C:\\tmp&gt; # it works!\n<\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_113704_ShareX_fullscreen.png\"><img loading=\"lazy\" width=\"1024\" height=\"576\" src=\"https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_113704_ShareX_fullscreen-1024x576.png\" alt=\"\" class=\"wp-image-1909\" srcset=\"https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_113704_ShareX_fullscreen-1024x576.png 1024w, https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_113704_ShareX_fullscreen-300x169.png 300w, https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_113704_ShareX_fullscreen-768x432.png 768w, https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_113704_ShareX_fullscreen-500x281.png 500w, https:\/\/montgomeryminds.com\/blog\/wp-content\/uploads\/2021\/04\/2021_04_02_113704_ShareX_fullscreen.png 1366w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<h2>Other Examples<\/h2>\n\n\n\n<p>Not all <code>exe<\/code> files have the problem. Here are some other famous exe&#8217;s that do, however. They&#8217;re in <code>C:\\Windows\\System32<\/code> (not <code>C:\\Windows\\<\/code> like <code>notepad.exe<\/code>):\n<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">    Directory: c:\\tmp\n\n\nMode                LastWriteTime         Length Name                                                                        \n----                -------------         ------ ----                                                                        \nd-----         4\/2\/2021   4:21 PM                en-US                                                                       \n-a----        3\/19\/2019  12:45 AM          34816 ipconfig.exe                                                                \n-a----        3\/19\/2019  12:45 AM          21504 ping.exe                                                                    \n-a----        3\/19\/2019  12:45 AM          17920 tracert.exe                                                                 \n-a----        3\/19\/2019  12:45 AM         369152 msinfo32.exe                                                                \n<\/pre>\n\n\n\n<p>And here are their associated .mui files:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">    Directory: c:\\tmp\\en-US\n\n\nMode                LastWriteTime         Length Name                                                                        \n----                -------------         ------ ----                                                                        \n-a----        3\/19\/2019   2:17 AM          28160 ipconfig.exe.mui                                                            \n-a----        3\/19\/2019   2:17 AM          11264 ping.exe.mui                                                                \n-a----        3\/19\/2019   2:17 AM           6656 tracert.exe.mui                                                             \n-a----        3\/19\/2019   2:17 AM          30720 msinfo32.exe.mui                                                            \n<\/pre>\n\n\n\n<p>Most programs do not have a <code>en-US<\/code>\\*.mui file in the first place. Here&#8217;s a few that do, but run fine when you copy them nevertheless:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">   Directory: c:\\tmp\n\n\nMode                LastWriteTime         Length Name                                                                        \n----                -------------         ------ ----                                                                        \nd-----        4\/14\/2021   4:55 PM                en-US-not_needed                                                            \n-a----        3\/19\/2019  12:45 AM          14336 HOSTNAME.EXE                                                                \n-a----        2\/20\/2021  11:33 PM         280064 cmd.EXE                                                                     \n-a----        3\/19\/2019  12:44 AM          86528 nslookup.exe                                                                \n-a----        3\/19\/2019  12:43 AM          40448 Netplwiz.exe                                                                \n-a----        3\/19\/2019  12:45 AM          40960 where.exe                                                                   \n-a----        3\/19\/2019  12:45 AM          71168 whoami.exe                                                                  \n<\/pre>\n\n\n\n<p><code>tasklist.exe<\/code> is interesting. It partially works when copied. It works without its <code>.mui<\/code> file, but only if you provide no parameters. If you want to provide parameters, you need the copied <code>.mui<\/code> file:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">    Directory: c:\\tmp\n\n\nMode                LastWriteTime         Length Name                                                                        \n----                -------------         ------ ----                                                                        \nd-----        4\/14\/2021   6:33 PM                en-us                                                                       \n-a----        3\/19\/2019  12:45 AM         101376 tasklist.exe                                                                \n\n\n    Directory: c:\\tmp\\en-us\n\n\nMode                LastWriteTime         Length Name                                                                        \n----                -------------         ------ ----                                                                        \n-a----        3\/19\/2019   2:17 AM          15872 tasklist.exe.mui                                                            \n<\/pre>\n\n\n\n<p>An oddball is <span style=\"font-size:120%\"><strong><code>mspaint.exe<\/code><\/strong><\/span>. It has a <code>.mui<\/code> but copying it <i>still<\/i> doesnt work. It may be interacting with the Windows 10 &#8220;App&#8221; interface.<\/p>\n\n\n\n<h2>References:<\/h2>\n\n\n\n<ul><li><a href=\"https:\/\/superuser.com\/questions\/279031\/copy-notepad-exe-from-system-folder-to-desktop-and-run-it\">https:\/\/superuser.com\/questions\/279031\/copy-notepad-exe-from-system-folder-to-desktop-and-run-it<\/a><\/li><li><a href=\"https:\/\/techcommunity.microsoft.com\/t5\/windows-blog-archive\/the-case-of-the-notepad-that-wouldn-t-run\/ba-p\/723535\">https:\/\/techcommunity.microsoft.com\/t5\/windows-blog-archive\/the-case-of-the-notepad-that-wouldn-t-run\/ba-p\/723535<\/a><\/li><li><a href=\"https:\/\/social.technet.microsoft.com\/Forums\/windowsserver\/en-US\/5cbb8581-a490-4571-a143-db7ba2e2a2a7\/why-wont-notepad-run-if-copy-to-another-location\">https:\/\/social.technet.microsoft.com\/Forums\/windowsserver\/en-US\/5cbb8581-a490-4571-a143-db7ba2e2a2a7\/why-wont-notepad-run-if-copy-to-another-location<\/a><\/li><\/ul>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>You might think you can just copy notepad.exe and run it: PS C:\\tmp&gt; copy C:\\windows\\notepad.exe c:\\tmp PS C:\\tmp&gt; dir c:\\tmp * Directory: C:\\tmp Mode LastWriteTime Length Name \u2014a\u2014\u2014\u2014\u2014 2\/20\/2021 11:35 PM 181248 notepad.exe PS C:\\tmp&gt; .\\notepad.exe PS C:\\tmp&gt; # Nothing &hellip; <a href=\"https:\/\/montgomeryminds.com\/blog\/you-cant-just-copy-notepade-exe-and-run-it-in-windows-10\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[10,9],"tags":[],"_links":{"self":[{"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/posts\/1907"}],"collection":[{"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/comments?post=1907"}],"version-history":[{"count":6,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/posts\/1907\/revisions"}],"predecessor-version":[{"id":1915,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/posts\/1907\/revisions\/1915"}],"wp:attachment":[{"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/media?parent=1907"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/categories?post=1907"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/montgomeryminds.com\/blog\/wp-json\/wp\/v2\/tags?post=1907"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}