As a beginner in coding, I am aware of the basics of batch files. However, I am struggling to locate the method of “closing” or halting the application prior to rerunning the code. This will prevent multiple cmd.exe windows from opening during each loop. Here is the current appearance of my .bat file.
Apologies in advance for any lack of clarity, as I am not well-versed in the command prompt or Windows 10. I am facing an issue with program permissions on standard user desktops. To resolve this, the program must be run “As Administrator,” but I would prefer to avoid requiring the client to constantly seek admin assistance. After extensive research (regrettably, I am unable to recall the source), I stumbled upon a useful line of code.
runas /user:admin_username /savecred "cmd /c "C:UsersFilesproject.exe""""
Frequently Asked Questions