Hi guys.
I have 2 buttons.
Button1:
Process.Start(start.bat)
and when I press button2 , I want start.bat to close..
How I can do that ????
Printable View
Hi guys.
I have 2 buttons.
Button1:
Process.Start(start.bat)
and when I press button2 , I want start.bat to close..
How I can do that ????
Create an object of Process class and use it to start it. After finishing you could kill that process via that object itself. Details: http://visualbasic.about.com/od/usingvbnet/a/prstrt.htm
Otherwise, you could kill process that you want by using this way: http://vbnetsample.blogspot.com/2007...l-process.html
:wave:
Your already creating a Process object. Process.Start returns a Process object. Just call Kill on that object.