CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Need a Custom or Prewritten Perl Program?: I need a program that...:
Need help to auto kill the process!!!


New User

Jan 19, 2010, 4:29 AM

Post #1 of 1 (3323 views)
Need help to auto kill the process!!! Can't Post


I am doing a simple automation thru perl code by just running a exe then do some normal renaming of files. Please find the below code.



# Running my exe file.
system "c:\\temp\\Search.exe";
print "hello";
system "ren c:\\temp\\Search.exe Search_after.exe";


I created a exe for the above program. So my output would be "find.exe".

If i execute the find.exe, a DOS window is opened and it is executing the Search.exe which is there in the C:\temp folder.

After this, i am finding 2 processes in Task manager 1) Find.exe 2) Search.exe. Upto this i am fine.

but the find.exe window is not disappearing by executing the whole code. Rather it is executing and stand there itself on first line.

So the subsequent codes which i have written in that program is not executed. If i kill that Search.exe from task manager, then it is

executing the other code and its process also disappears from taskmanager.

What I want now?

1) I wanted to keep that Search.exe should be running.

2) I wanted to execute all the code in the Find.exe then it should auto close as per the normal exe file execution behavior.

Can any one please answer my questions?


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives