One could foreseeability use .NET 4 today. There are a few ways this could be accomplished, however most of them are not very elegant.
Thanks for the reply , what I'd like to know when will .NET 4 be officially supported (if there are any plans for this soon)
In the mean time, could you elaborate on the "non elegant" ways you mentioned ?
I have no knowledge of the time-line, however implementations that may work for now are:
1.) .NET 4.0 Silent Install
Simply including the .NET 4.0 redistributable as a post installa action (silently) may work as well. It would require testing on XP and 7 to ensure it was truly silent and graceful. Command line switches similar to these would be needed:
/install /x86 /x64 /ia64 /parameterfolder Client /q /norestart
2.) Pre-loader written in .NET 3.5
Create a .NET 3.5 pre-loader exe. This exe functions as the target for your primary shortcuts, and it checks for the .NET 4.0 dependency. If needed it launches the .NET 4.0 installer (you could do a web installer or local redistributable). Once the dependency is satisfied you exec your primary executable.
The catch is that you would need to call the AppUp SDK from your pre-loader, and ensure the main (.NET 4.0) exe had some form of protection so that it could not be executed without AppUp SDK protection.
* Some developers have went so far as to add AppUp SDK authorization calls to both the pre-loader and the primary executable.
Please let me know if I can be of any further assistance.
Thanks for the details Brian.
I did notice in the validation guidelines that it says apps will be rejected if they are submitted in .NET 4.
Is this incorrect?
If the primary executable (as installed), is .NET 4.0 then yes. However, if one of the implementations above is used it may pass the validation process. The only way to know for certain is to be the first one to try this solution. Please let me know if I can be of further assistance.
If you get stuck, please let me know. I can put a quick example/guide together.
Hi Brian, a small step by step guide on how to do this would actually be great if possible.
thanks in advance,
In above post you mention silent install of .Net 4.0. Which tool I can use to implement that custom action: InstallShiled, Wix?
Is it possible for you to have a small guid up as it will benefit a lot.
Is there any news on this?
Has anyone managed to install a .net 4 app for AppUp using the suggested methods?
If you were to have a preloader application, how would it launch a silent install of .net 4.0, surely this would be caught by UAC, once your preloader is installed and run will it have the necessary privileges to run an installer?
I would suggest to silently install .NET 4 in a custom action at the end of the install process.
Although I'm not using .NET 4 myself, I used a custom action several times e. g. to silently install a printer driver at the end of an installation. This passed validation without problems, so I don't see are reason why there should be problems with .NET 4 here.
The only thing is, of course, that including .NET 4 in the installer itself, will heavily increase the installer size. But I guess this should not be a problem for validation, too.
Can you give me any code examples of how to do that?
I found this;
the link you found tells you how you have to start the .NET 4 setup within your product install. This way it runs silently.
And to start it in the install process (when using a Visual Studio setup project for creating your MSIs) you need to create a customer action if you don't have one yet. Here you can find how to do that:
Then you start a new process with the command line you found in the "AfterInstall" step.
As I said I never used that to install .NET 4 myself, but it works fine with my driver setups. So I guess it'll work with the .NET 4 setup, too.