开发者

Setup project: Adding .NET and Windows Installer prerequisites results in large installer

开发者 https://www.devze.com 2023-04-02 12:31 出处:网络
I\'ve created my program successfully. Now, I want to publish it. I\'ve created a Setup Project in order to make an installation file. I\'ve added .NET 4.0 Client and Windows Installer as project prer

I've created my program successfully. Now, I want to publish it. I've created a Setup Project in order to make an installation file. I've added .NET 4.0 Client and Windows Installer as project prerequisites (via Setup Project PropertiesPrerequisites). After that, I build my project.

This produces these files:

Setup files, .NET 4.0 Client, Windows Installer

But .NET 4.0 Client and Windows Installer make my project most biggest. So I would like to know if there is a way to make my set开发者_如何学编程up file contain just the required libraries, i.e. the setup program won't install .NET on the target host?


No I don't think so - without the .net framework your are screwed here.


When you do this the .NET framework is not included in the MSI package and doesn't make the file any bigger. It is only a pre-requisite for the successful installation. So when you run the setup on the client computer if it already has the framework installed it won't do anything. If it doesn't it will ask the client to download it. You could of course remove this prerequisite but because your application is built with .NET if the client computer doesn't have the correct version installed your application won't run. So I would suggest you to leave this prerequisite in your setup project.

0

精彩评论

暂无评论...
验证码 换一张
取 消