Enabling XP themes (Only Exe Project Type)


Easy Code allows you to automatically include an XP theme manifest in a project. XP themes enable the Windows Common controls 6.0 in order to take advantage of the new look for controls in Windows XP and later. A manifest is just a text file in XML format, and for Easy Code to be able to include it in the executable, the manifest file must be named Manifest.xml and it has to be in the project's Res folder. Besides, you must mark the Manifest.xml file option in the Project properties. That way, it will be included in the executable file as a resource and the new controls will be enabled. Below is a simple example of an XP theme manifest:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<assemblyIdentity
    version="1.0.06.0001"
    processorArchitecture="x86"
    name="EasyCode.exe"
    type="win32"
/>
<description>Assembly visual programming environment</description>
<dependency>
    <dependentAssembly>
        <assemblyIdentity
        type="win32"
        name="Microsoft.Windows.Common-Controls"
        version="6.0.0.0"
        publicKeyToken="6595b64144ccf1df"
        processorArchitecture="x86"
        language="*"
        />
    </dependentAssembly>
</dependency>
</assembly>

You just have to replace the version, name and description fields (those shown in blue bold font). This option includes the manifest in the executable file as a resource (the way I prefer), but you can also include a manifest naming the XML file with the same name of the executable plus .manifest. For example, for a program named AppName.exe the manifest file should be named:

AppName.exe.manifest

So change the XML file name to AppName.exe.manifest and place it in the same directory than the EXE file:

AppName.exe
AppName.exe.manifest


Try to include a Manifest file in all of the examples coming with Easy Code, rebuild them, and see the look of the new common controls in Windows XP and later.


IMPORTANT: From version 1.03.0.0001 and later, Easy Code can create a default Manifest.xml file and include it in the project. For more information, please read the STARTING EASY CODE and Including a Manifest in the project topics.

REMARKS: At design time, or when testing a window, all control objects will be shown with the new common controls style if the Manifest.xml file option is selected in the Project properties. Otherwise, they will be shown with the old controls style.

WARNING: Take into account that the Manifest.xml file has no effect for Windows systems prior to XP.