CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5

Thread: XP Look in VC 6

  1. #1
    Join Date
    Nov 2002
    Posts
    42

    XP Look in VC 6

    I'm using windows XP how do I get the XP look in a project created on VC 6?

  2. #2
    Join Date
    Apr 2003
    Location
    UK
    Posts
    83
    Create a manifest file call myapp.exe.manifest (where myapp is the name of your application. Put this in it:

    Code:
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?> 
    <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0"> 
    	<assemblyIdentity 
    		version="1.0.0.0" 
    		processorArchitecture="X86" 
    		name="MyCompany.MyProduct.MyProduct" 
    		type="win32"/> 
    	<description>Some description.</description> 
    	<dependency> 
    		<dependentAssembly> 
    			<assemblyIdentity 
    				type="win32" 
    				name="Microsoft.Windows.Common-Controls" 
    				version="6.0.0.0" 
    				processorArchitecture="X86" 
    				publicKeyToken="6595b64144ccf1df" 
    				language="*"/> 
    		</dependentAssembly> 
    	</dependency> 
    </assembly>
    The manifest tells Windows to use the version 6 common controls. Put the manifest file in the same directory as your exe.

  3. #3
    Join Date
    Nov 2002
    Posts
    42
    Thanks for the answer, but I didn't manage to get the XP Look.
    I put the file under the res directory and under the Debug directory, I have inserted in the .RC file the following line:
    IDR_MANIFEST RT_MANIFEST "res\\XPLook.manifest"
    and in the Resource.h file the following line:
    #define IDR_MANIFEST CREATEPROCESS_MANIFEST_RESOURCE_ID

    Is something missing?

  4. #4
    Join Date
    Apr 2003
    Location
    UK
    Posts
    83
    Does this help?

  5. #5
    Join Date
    May 1999
    Location
    Southern California
    Posts
    12,266
    As far as I know, you just have to build the project. I use XP but I don't use the XP look. I wanted to show my program using the XP look so I changed my theme to use it. My program was shown using the XP look (or at least I thought it did).
    "Signature":
    My web site is Simple Samples.
    C# Corner Editor

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured