Reputation: 95
Suppose that I will target my Winforms
application to Framework 4.5, but the user machine only has the Framework 3.X, and the user attempts to run the application, then the application will not run because the needed framework version is not installed on the machine...
...but there is a way to perform from my app an smart preventive operation in that case? (instead of let windows OS to display a non-friendly error msgbox)
What I want to do is for example show a msgbox to recommend the user to download X framework package in X url to be able to run the app, only if the required framework is not installed on the machine.
Upvotes: 1
Views: 190
Reputation: 8892
You can simply do this by changing the setting under prerequisite of the Setup project.
properties
Prerequisite
buttonDownload the prerequisite from the component vendor's web site
When the target machine doesn't have the .net frame work instead of error message it will display download link to download .net framework.
Upvotes: 1