XP system, because to run a cracking software, the date must be 2011-02-01, in order to run the software, requirements, run this batch first record today is XX X month X day, then change the date to 2011.2.1, and then run artcampro.exe file, batch processing in the background silently run, 30 seconds to judge artcampro.e. Whether the Xe process exists or not, if it does not exist, change back to the original date
In fact, I also have some ideas, that is, I feel troubled. I hope that the batch processing experts can help me. After solving the problem, we must add a reward to copy and paste the Party, which will not be used.
START “” d:\artcampro.exe
ping -n 31 127.1>nul
tasklist |FIND “artcampro.exe”>nul
IF %errorlevel%==1 (DATE %y%/%m%/%d%&&EXIT) else (GOTO loop)
A 30-second loop detects whether the process exists and exits the batch if it does not exist.
Question: If I run this software several times, will there be several such processes at the same time?
Answer: It depends on whether the program runs continuously several times, that is to say, the previous program (artcampro.exe) has not been closed. I just wrote this to judge whether there are, not to judge how many. As “according to Mengqin Yao” said, start/wait wait for the program to end. This can be used to start a program.
Question: I don’t know about start/wait. If you close the artcampro.exe program, you can change the time back. That’s the best.
So how should I write it?
START /WAIT “” d:\artcampro.exe
Question: I didn’t know START/WAIT before. Today I have long knowledge. Thank you, and thank you all for your answers.
Questioner Comments: Thank you again
Three other answers
tasklist|find /i “artcampro.exe” || goto begin
ping -n 30 127.0.0.1>nul
set /p d=<1.txt
Start / wait, you can see the command help
WAIT starts the application and waits for it to terminate.
If it is an internal CMD command or batch file, the command processor uses
The cmd.exe/K switch is running. This means that after running the command, the window
It will still exist.
If it is not an internal CMD command or batch file, then it is a program and will
Run as a window application or console application.
Yyykkkyyyy | 13
Help you lazy batch processing put the artcampro.exe program in the same location and send shortcuts to the desktop. If the program has been enabled and is running before, it will not start again and change the date.
if “%~1″==”h” goto begin
if not exist hide.vbs (
echo Set ws = CreateObject(“Wscript.Shell”^)
echo ws.run “cmd /c %~s0 h” ,vbhide)>hide.vbs
start “” /wait “artcampro.exe”
Yimeng Qinyao | Know from Mobile Phone | 13
In fact, it does not need to detect, just use the start / wait command to let the batch waiting program end, so you can combine the content of jd08139 as a friend.