RSS

Tag Archives: program

C# Windows Vista/7 Program Might Not Have Installed Correctly

If you include the word “Installer” in your Visual Studio Project, you may run into issue when executing your program on a Windows Vista or 7 machine.

Visual Studio will tag your application as an installation application.  If you do not have the correct settings in your application manifest file, it will display something along the lines of:

This program might not have installed correctly

There may also be an option to reinstall using recommended settings or to you can select the installation did work as expected.

Remedy:

  1. Add an application manifest to your file by right clicking in the Project and selecting Add New Item.
  2. Open the app manifest and include the following:

    <compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">

    <application>
    <!--The ID below indicates application support for Windows Vista -->

    <supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>

    <!--The ID below indicates application support for Windows 7 -->

    <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>

    </application>

    </compatibility>

  3. Save your app manifest file and ensure it is the selected one in your Project’s Properties Application tab.
 
Leave a comment

Posted by on August 9, 2011 in .net, c#

 

Tags: , , , , , ,