在运行现有控制台应用程序时打开新的控制台应用程序)
如何在运行现有控制台应用程序 (1) 时打开新的控制台应用程序 (2)?
static void Main(string[] args)
{
try
{
Console.WriteLine("success");
//how to close this console
}
catch (Exception ex)
{
Console.WriteLine("Error Due To: " + ex.Message);
}
finally
{
//code for opening the second console....(is that passible)
//how to close this console
}
}
Possible Duplicate:
Is there a way to create a second console to output to in .NET when writing a console application?
How to open a new console application (2) while running the existing console app (1)?
static void Main(string[] args)
{
try
{
Console.WriteLine("success");
//how to close this console
}
catch (Exception ex)
{
Console.WriteLine("Error Due To: " + ex.Message);
}
finally
{
//code for opening the second console....(is that passible)
//how to close this console
}
}
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
请参阅
Process
类编辑:类似的内容,但您必须注意,每次先前版本关闭时,这都会创建应用程序的新实例! (这是你想要的吗?)
See
Process
ClassEdit: Something like that, but you have to notice that this will create a new instance of the application every time the previous version closed! (is that what you want?)