不启动控制台的 .Net 控制台应用程序 [英] .Net Console Application that Doesn't Bring up a Console

查看:33
本文介绍了不启动控制台的 .Net 控制台应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个控制台应用程序,用于通过 Windows 调度程序运行计划作业.与应用程序之间的所有通信都在电子邮件、事件记录、数据库日志中.有什么办法可以抑制控制台窗口出现吗?

I have a console application I'm using to run scheduled jobs through windows scheduler. All the communication to/from the application is in email, event logging, database logs. Is there any way I can suppress the console window from coming up?

推荐答案

当然.将其构建为 winforms 应用程序,从不显示您的表单.

Sure. Build it as a winforms app and never show your form.

请小心,因为它不再是真正的控制台应用程序,并且在某些环境中您将无法使用它.

Just be careful, because then it's not really a console app anymore, and there are some environments where you won't be able to use it.

这篇关于不启动控制台的 .Net 控制台应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆