可以将Asp.net网站转换为桌面c#应用程序,用于本地PC使用.. [英] IT is Possible to Convert Asp.net Website To Desktop c# Application,For Local Pc Use..

查看:60
本文介绍了可以将Asp.net网站转换为桌面c#应用程序,用于本地PC使用..的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的网站名称为www.xyz.com,我使用C#代码制作..

它在线运行并且运行良好.......



现在我需要的是创建一个在本地PC上运行的应用程序,我还创建了安装应用程序的安装程序,



我希望该应用程序具有与我的网站相同的功能和设计..





所以我的问题是....

1.有任何技巧可以直接将网站转换为应用程序或本地PC使用设置吗?

2.或者我再次完全申请并从我的asp.net网站复制必要的代码。 ?

3.在WebSite中工作的相同代码也适用于Web应用程序???







Plz给我一些想法...



:删除了网站链接

i have a website name as www.xyz.com which i made using C# code..
it run online and work very well.......

Now My need is Create a Application Which run on Local PC,and i also create Setup for install the application,

I want that application have Same Functionality and Design Like my Website..


So my Question is....
1. There are any Trick to directly convert website to application or Setup for Local PC use ?
2. or i made full application again and copy necessary code from my asp.net Website.. ?
3. Same code which work in WebSite also work in Web application ???



Plz give me Some Ideas...

: Website link removed

推荐答案

检查

演练:转换将网站项目导入Visual Studio中的Web应用程序项目 [ ^ ]


你好,



它将ASP网站转换为桌面应用程序并不简单!实际上你可能需要重写所有这些!



但是你可以用一个技巧......



您可以编写一个使用webbrowser控件的winform或wpf应用程序,而不是重写您的网站。

http://msdn.microsoft.com/en-us/library/system.windows.forms.webbrowser(v = vs.110) .aspx [ ^ ]



然后使用像CassiniDev这样的网络服务器在设备上本地运行您的网站。

http://cassinidev.codeplex.com/ [ ^ ]



这应该可行!您可以在桌面应用程序内的设备上本地运行您的网站。你可以根据自己的意愿使桌面应用程序的UI变得复杂,如果你仔细地使用你的网站CSS,你可以使网站看起来像是桌面应用程序。



希望它有所帮助。



Valery。
Hello,

It is not straight forward to convert a ASP website to a desktop application! Actually you may need to rewrite all of it!

BUT there is a trick you could use...

Instead of rewriting your website you could write a little winform or wpf application that uses the webbrowser control.
http://msdn.microsoft.com/en-us/library/system.windows.forms.webbrowser(v=vs.110).aspx[^]

Then use a webserver like CassiniDev to run your website locally on the device.
http://cassinidev.codeplex.com/[^]

That should do the trick! you get your website running locally on your device inside a desktop application. You can make the UI of your desktop app as complicated as you wish and if you carefully work on your site CSS you could make the site look like if it is a desktop app.

Hope it helps.

Valery.


这篇关于可以将Asp.net网站转换为桌面c#应用程序,用于本地PC使用..的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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