软件设置创建 [英] Software Setup creation

查看:75
本文介绍了软件设置创建的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





我在Visual Studio 2010中创建了一个桌面应用程序,并在后端使用了Sqlserver 2005.



现在我想为我的应用程序创建一个设置。但我不希望Visual Studio安装项目中提供Setup.exe选项。我想要的是所有先决条件,如.net框架工作和Sql Server和我的应用程序以平滑和有吸引力的方式安装。例如,如果系统上没有安装sql server而不是它应该安装的数据库文件和附加到它的数据库文件。



我已经阅读了一些文章但是无法完成解决方案。



任何形式的帮助将不胜感激。在此先感谢。





再见。

解决方案

你的想法避免使用VS安装附带的安装项目模板是有道理的。微软从较新版本的Visual Studio中删除了这部分产品,我认为这有一些很好的理由。微软正在摆脱它而不用其他任何东西替换它。那么,该怎么办?



我的解决方案是使用开源安装工具集开源WiX:

http://en.wikipedia.org/wiki/WiX [ ^ ],

http:// wixtoolset .org [ ^ ]。



我最近迁移到它,我很高兴我做到了。它也不完美(整个Microsoft Installer及其API远远落后于其他技术),但它比我迄今为止听过的任何内容都要好得多。实际上,如果你使用WiX,你会明白上面提到的工具实际上几乎是非法的(技术上),他们正在使用他们的专有项目文件。只有WiX能够很好地符合现代MSBuild和相关的基于XML的项目标准,因此您可以使用标准MSBuild技术来使用WiX项目:定制它,与更大的主项目或解决方案集成,编写您自己的扩展,如果您需要的话,以及等等。



此外,它与不同版本的Visual Studio非常顺畅地集成。



最后,一个很大的好处是:WiX代码是非可视的。使用一些官方记录的XML方案,在XML代码中显式声明了所有内容。 XML代码文件背后没有任何内容。



关于行为和功能,很遗憾,很多高级功能都没有全面记录。但社区已经收集了大量经验并提供了许多有用的建议。到目前为止,我能够找到我真正需要的所有家务的解决方案。并且我在旧版安装项目中找到了一套随时可用的解决方案。需要开发自定义步骤的一些操作已经嵌入到WiX中。它包括将Windows防火墙调整到您的应用程序,设置文件和目录的权限,根据项目平台和目标平台的不同操作等等。



-SA

Hi,

I have created a desktop application in Visual Studio 2010 and used Sqlserver 2005 at back end.

Now i want to create a setup for my application. But i do not want Setup.exe option as available in Visual Studio Setup project. What i want is that all the prerequisites like .net frame work and Sql Server and my application installed in a smooth and attractive manner. e.g if sql server is not installed on the system than it should be installed and data base files attached to it.

I have read some articles but could not get a complete solution.

Any kind of help will be appreciated. Thanks in advance.


bye.

解决方案

Your idea to avoid using Setup project template which comes with VS installation makes some sense. Microsoft removed this part of the product from newer versions of Visual Studio, and, I think, for some good reasons. Microsoft is getting rid of it without replacing it with anything else. So, what to do?

My solution is using open-source WiX, the open-source installation toolset:
http://en.wikipedia.org/wiki/WiX[^],
http://wixtoolset.org[^].

I recently made a migration to it and am very glad I did. It's not perfect too (and the whole Microsoft Installer and its API is well behind other technologies), but it is much better than anything I ever heard of so far. Actually, if you use WiX, you will understand that the tools mentioned above are actually nearly illegal (technically), they are using their proprietary project files. Only WiX provide excellent compliance with the contemporary MSBuild and related XML-based project standard, so you can use WiX projects using standard MSBuild techniques: customize it, integrate with bigger master projects or solutions, write your own extensions, if you need some, and so on.

Also, it has very good and smooth integration with Visual Studio of different versions.

Finally, one big benefit is: WiX code is non-visual. Everything is explicitly declared in XML code using some official documented XML scheme. Nothing is hidden behind the XML code files.

As to the behavior and features, many advanced features are not comprehensively documented, unfortunately. But communities already collected considerable experience and provide a lot of useful advice. So far, I was able to find solutions to all chores I practically needed. And the set of ready-to-use solutions is wider that that I found in a legacy Setup project. Some actions which required development of custom steps are already embedded in WiX. It includes adjusting Windows Firewall to your application, setting permissions of files and directories, different action depending on the project platform and target platform, and a lot more.

—SA


这篇关于软件设置创建的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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