Thursday, June 15, 2017

windows 7 - Unable to run batch file

I'm trying to run a .bat file which contains the below code


echo "Test"
pause

It throws the following error


Windows cannot find 'c:\Users\test\Desktop\run.bat'.
Make sure you typed the name correctly, and then try again.

enter image description here


The above user has all administrator rights.


But when I run this .bat as Run as Administrator it is executing properly. I tried running in new user account with admin privileges but still no luck.


I tried to modify regedit:


Hkey_Current_User\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.bat

But .bat key doesn't exist there.

No comments:

Post a Comment

hard drive - Leaving bad sectors in unformatted partition?

Laptop was acting really weird, and copy and seek times were really slow, so I decided to scan the hard drive surface. I have a couple hundr...