开发者

Threading in VB.Net Console Application

I have a console application that is built in VB.Net. Now I have a timer in that application. All I want to do is at a particyualr time i will call another exe (which is built in VB 6.0) and again get the control back to this console application. Now what is happening is that I am being able to call the second exe from the console application , but then the control is开发者_如何学JAVA not returning back to the same console application. Any help will be much appreciated. Thank you in advance


Process.Start(myProgramPathAndFileName)

This should create a new process and return control to your console app.

You can do more with this process by storing the return value:

MyProcess = Process.Start(myProgramPathAndFilename)

Then call this when your application exits

MyProcess.Kill

See: http://msdn.microsoft.com/en-us/library/system.diagnostics.process.aspx for more info on processes.

See: .NET Console Application Exit Event for information on handling Application Exit as an event.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜