Windows xp run batch file in background
Manoj Manoj 4, 12 12 gold badges 50 50 silver badges 74 74 bronze badges. Add a comment. Active Oldest Votes. Add your program in the registry : Run - These are the most common startup locations for programs to install auto start from.
CreateObject "Wscript. Improve this answer. VonC VonC 1. Two other startup posibilties: you could always add the bat file to the startup folder, or start it as a Scheduled task setting to run on logon. Ori Ori. I want to run it without the command window gettng popped up.
You can make an application run as a service. Klathzazt Klathzazt 2, 19 19 silver badges 27 27 bronze badges. I was thinking windows resource kit would not work on Windows Xp. But it seems it installs on XP too!.. You could run your batch file from a VBscript in invisible mode and place the vbscript in the start up programs directory.
I've updated my answer to include this method. WRJ, if this helped or solved your issue, would you mind voting up the answer? This is a VBS file. This monitors for notepad exiting, pops up a messagebox, and restarts notepad. CreateObject "WScript. NextEvent msgbox objReceivedEvent. ProcessName If lcase objReceivedEvent. ExitStatus WshShell.
Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. Possible, but not exactly what I am after direct asynchronous call in background — VonC. This uses a third-party tool called NirCmd. Make a script containing this code: echo off nircmd exec hide "MainScript. Make sure they are in the same directory, and download NirCmd into the same directory.
Interesting option, from github. Is it yours? Also, I did not know about unblocked CMD! Haha, unblocked CMD is a tool I use when services let you use bat scripts but not command prompt. Right: nirsoft. However, as said here : "I'd feel differently if Nir Sofer released source. I haven't changed anything, just uploaded a direct mirror to my GitHub.
You can run your. Vinod Chelladurai Vinod Chelladurai 6 6 gold badges 14 14 silver badges 26 26 bronze badges. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Stack Gives Back Safety in numbers: crowdsourcing data on nefarious IP addresses.
Featured on Meta. New post summary designs on greatest hits now, everywhere else eventually. Linked See more linked questions. Related This fails, for a reason I did not yet discover. As mentioned above, if the batch file is ran directly it doesn't fail. It seems to be possible to schedule task for user login session with schtasks.
It might not be what you want, so using a full non-substed path might be the best solution after all. Stack Overflow for Teams — Collaborate and share knowledge with a private group. Create a free Team What is Teams? Collectives on Stack Overflow. Learn more. Batch file not working when running in the background - issue with substituted drive Ask Question. Asked 8 years, 11 months ago. Active 8 years, 11 months ago. Viewed times.
0コメント