你能从ASP.NET向C#windows表单应用程序发送消息吗? [英] Can you send a message from ASP.NET to C# windows form application?

查看:71
本文介绍了你能从ASP.NET向C#windows表单应用程序发送消息吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,是否可以将消息从ASP.NET网站发送到C#Windows窗体应用程序?我希望服务器能够以人们无法找到消息发送方式的方式进行通信。



我尝试了什么:



研究,但我找不到任何我正在寻找的东西。

Hello, is it possible to send message from ASP.NET website to C# Windows Form Application? I want the servers to communicate in a way that people can't find out where the message is sent.

What I have tried:

Research, but I can't find anything I'm looking for.

推荐答案

Web应用程序使用HTTP / HTTPS(如ASP.NET)始终是请求/响应类型的应用程序。客户端发出请求,服务器向其发送响应。 Web服务器永远不会随意向客户端发送任何内容而无需客户端请求它。



因此,从直接意义上说,不,你不能发送一个从网络应用程序发送到客户端的消息。



但是,您可以使用其他技术,例如 SignalR [ ^ ]。
Web applications using HTTP/HTTPS, like ASP.NET, are always request/response type apps. The client makes a request and the server sends a response to it. A web server NEVER arbitrarily sends anything to a client without the client making a request for it.

So, in a direct sense, no, you can't send a message from the web app to the client.

But, you can using other technologies, like SignalR[^].


这篇关于你能从ASP.NET向C#windows表单应用程序发送消息吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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