Created
January 15, 2017 07:18
-
-
Save Rottweiler/377b9805ef48fc7e673d3a6c1b7551ea to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static void FakeFrameworkWarning() | |
{ | |
StringBuilder sb = new StringBuilder(); | |
sb.AppendLine("This application requires one of the following versions of the .NET Framework:"); | |
sb.AppendLine(".NETFramework,Version=v4.5.2"); | |
sb.AppendLine(); | |
sb.AppendLine("Do you want to install this .NET Framework version now?"); | |
DialogResult res = MessageBox.Show(sb.ToString(), Process.GetCurrentProcess().MainModule.ModuleName + " - This application could not be started.", MessageBoxButtons.YesNo, MessageBoxIcon.Error); | |
if (res == DialogResult.Yes) | |
{ | |
Process.Start("http://dotnetsocial.cloudapp.net/GetDotnet?tfm=.NETFramework,Version=v4.5.2"); | |
} | |
else | |
{ | |
Environment.Exit(0); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment