Reputation: 107
I have an msi project within Visual Studio 2005 c#. I have selected the: "Install .Net 2.0" within the prequisite of the msi and selected the option to run the msi from the current location, thus having the .Net installation directory together with the msi instead of downloading it from windows web site, to save the user's time. When running this msi on windows 8, I get a message that the app requires >net 2.0 and needs to download .Net 3.5 from the internet.
My question is, how can I add .Net 3.5 using Visual studio 2005 to my prequiste msi? or is there on-the-fly solution, so I can add the .Net 3.5 installation directory together with the msi and let the msi/ or vb script install this directory instead of downloading the .Net from the internet.
Upvotes: 1
Views: 2290
Reputation: 55620
I suspect the easiest "solution" to your problem is compile your assemblies with .NET 2.0 (CLR 2.0) but manifested to allow running on .NET 4.0 / 4.5 (CLR 4.0).
Running .NET 2 Runtime applications under the .NET 4 Runtime
Then in your installer, configure the prereq to be skipped in a newer version of .NET is detected. You'll have to test these scenarios but it should just work. FWIW it's unlikely that you actually need .NET 2.0/3.5 on Windows 8. .NET 4.0/4.5 should suffice.
Upvotes: 1