问题描述
我正在为我的.NET 3.5 SP1 WPF应用程序构建一个自定义的Windows安装程序包。我想要它检测在客户端的计算机上安装了什么版本(如果有的话)的.NET框架,然后如果没有,请自动从Microsoft下载。现在,我已经阅读了.NET引导程序,甚至在我制作的ClickOnce安装程序中看到它。它似乎只是我需要的。
问题是,我不想使用ClickOnce。我偏偏NSIS。所以本质上我正在寻找一些关于如何与某些方式进行通信或集成引导程序的文档,所以我可以在自己的安装程序中利用它。但是我没有找到太多的东西。
任何帮助将不胜感激。
谢谢
Steve
你会想要一些,除非我使用它,它只能最多检测到2个。我现在在家,但是当我上班的时候,我会发布我的这个代码,使其工作到3.5 SP1。他们更改了版本号的位置。
编辑:发布我的版本
I'm building a custom Windows installer package for my .NET 3.5 SP1 WPF application. I want it to detect what version (if any) of the .NET framework is installed on the client's computer, and then automatically download it from Microsoft if they don't have it.
Now, I've read about the .NET bootstrapper and even seen it in action in a ClickOnce installer I made. It seems to do just what I need.
The problem is, I don't want to use ClickOnce. I'm partial to NSIS. So essentially I'm looking for some documentation on how to communicate with or integrate the bootstrapper in some way so I can leverage it inside my own installer. But I'm not finding much.
Any help would be greatly appreciated.
Thanks,Steve
You'll want something like this, except when I've used this it only detects up to 2 properly. I'm at home now but when I get to work I'll post my hack of this code to make it work up to 3.5 SP1. They changed the location of the version number a little.
Edit: Posted my version on pastebin
这篇关于如何与.NET 3.5 SP1引导程序通信的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!