简体   繁体   English

是否可以将ASP.NET应用程序部署为桌面应用程序(带有服务器组件)

[英]Is it possible to deploy an ASP.NET application as desktop application (with server component)

Question: I created an ASP.NET web application. 问题:我创建了一个ASP.NET Web应用程序。

Now it originally was meant for deployment on a webserver. 现在它原本是打算在Web服务器上部署的。
That is working, so, so far so good. 到目前为止,效果很好。

My question now is: Is it possible to deploy it as a desktop-application, too? 我现在的问题是:是否也可以将其部署为桌面应用程序?

That is to say the installer installs some kind of server, plus the web application, configures the server to run this application on a localhost URL, and then creates a link in the start menu/desktop, where it opens that url (website, the application) on localhost in a web browser? 也就是说,安装程序将安装某种服务器以及Web应用程序,将服务器配置为在本地主机URL上运行该应用程序,然后在开始菜单/桌面中创建链接,并在其中打开该URL(网站,应用程序)在Web浏览器中的localhost上?

I think it should be possible, though the server wouldn't be IIS, because this is a windows component which can't be separately installed. 我认为应该可以,尽管服务器不是IIS,因为这是Windows组件,不能单独安装。

Is there anything like this already out there ? 已经有这样的东西了吗? The nonplusultra would be that it only starts the server when you click on the shortcut. 非多余的是,仅当您单击快捷方式时,它才会启动服务器。

I'm not sure, but you could use IIS express, when it will be released. 我不确定,但是可以在发布时使用IIS express。 Take a look to ScottGu's post Introducing IIS Express . 看一下ScottGu的IIS Express简介。

I almost went for Cassini. 我差点就去卡西尼了。
But in the meantime, I found something better: 但与此同时,我发现了一些更好的方法:

http://code.google.com/p/aspnetserve/ http://code.google.com/p/aspnetserve/

My mistake was searching for 'asp.net deployment server component' instead of 'asp.net embedded webserver'. 我的错误是搜索“ asp.net部署服务器组件”而不是“ asp.net嵌入式Web服务器”。

A really cool project. 一个非常酷的项目。
Seems to work, at least for my needs. 似乎可以工作,至少满足我的需求。

Edit: 编辑:
A much better choice is xsp4 from package xsp-2.10.2, courtesy of the mono-project. 更好的选择是xp-2.10.2软件包中的xsp4,这要取决于mono-project。
http://download.mono-project.com/sources/xsp/ http://download.mono-project.com/sources/xsp/
Works on both Linux and Windows, as well as Mac, with both mono and .NET framework, and that without GAC installation (in fact, without any installation). 在具有mono和.NET框架的Linux和Windows以及Mac上均可运行,并且无需安装GAC(实际上,无需任何安装)。

The latest source is here: 最新资源在这里:
https://github.com/mono/xsp/tree/master/src https://github.com/mono/xsp/tree/master/src

您可以使用易于安装的ASP.Net Web服务器,例如UltiDev Cassini

I think what you are looking for is something like Adobe Air: http://en.wikipedia.org/wiki/Adobe_Integrated_Runtime 我认为您正在寻找的是Adobe Air: http//en.wikipedia.org/wiki/Adobe_Integrated_Runtime

However you want to be able to run ASP.NET, which Adobe Air does not. 但是,您希望能够运行ASP.NET,而Adobe Air则不能。 My suggestion is to use Silverlight 我的建议是使用Silverlight

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM