如何设计一个 .net windows 窗体应用程序,当用户注销远程桌面连接时永远不会退出
我对 Windows 窗体应用程序开发非常陌生。我在远程 IIS 服务器上安装了一个应用程序,该应用程序是一个代理,每 10 分钟检查和处理作业队列一次。
但是,如果我在服务器上单击“开始”-“注销”来断开我的远程桌面连接会话。应用程序也会退出。
是否有办法将 Windows 窗体应用程序设置为保留,除非服务器重新启动或关闭?
我知道 Windows 服务应用程序可以做到这一点,但在这个业务案例中,Windows 服务应用程序不会是替代解决方案。
I am quite new to windows form app development. I have an app installed on a remote IIS server, this app is an agent that check and process job queue every 10 minutes.
But if I click "Start" - "Log off" on the server to disconnect my Remote Desktop connection session. The application quits as well.
Is there anyway to setup the windows form app to keep unless until a server restart or shutdown?
I know windows service applciation can do that but in this business case, windows service app will not be an alternative solution.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Windows 表单应用程序无法满足您的要求。表单应用程序在登录的用户上下文中运行,并在您注销时停止执行。如果您无法使用 Windows 服务,则必须寻找其他方法。
A Windows forms app just won't do what you're asking for. Forms apps run in the logged-on user context and stop executing when you log off. If you can't use a Windows service, you'll have to find another way.