Results 1 to 11 of 11

Thread: WinXP buttons, etc.

  1. #1

    Thread Starter
    Addicted Member donut's Avatar
    Join Date
    Mar 2001
    Location
    London, UK
    Posts
    165

    WinXP buttons, etc.

    anyone know how can i make my program use winxp-style controls, rather than the boring old classic stuff?

  2. #2

  3. #3

    Thread Starter
    Addicted Member donut's Avatar
    Join Date
    Mar 2001
    Location
    London, UK
    Posts
    165
    hmmm, but that only appears to be for various controls, and i don't really want to use third party stuff. surely there must be some API you can use that tells winxp to use winxp-style controls? i mean, many programs are now developed to support xp, and use xp-style controls.

  4. #4
    Frenzied Member
    Join Date
    Aug 2000
    Posts
    1,539
    i swear i had a direct link to this

    damn it where did it go

    anyways
    search for "MANIFESTS" on ms site

  5. #5
    Frenzied Member
    Join Date
    Aug 2000
    Posts
    1,539
    Code:
    Follow these steps to introduce Windows XP visual styles into your Windows
    application.
    
    1. Create a new Windows Application and add some controls to the default 
    form.
    
    2. For every control you place on the form that has a FlatStyle property, 
    set
       the property to System.
    
    3. Compile your application.
    
    4. Build a manifest file in the application directory. NOTE: This manifest 
    file
       must be located in the same directory as the executable.
    
       Open Notepad and place the code shown below in the file.
    
       <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
       <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
       <description>.NET control deployment tool</description>
       <dependency>
               <dependentAssembly>
                       <assemblyIdentity
                               type="win32"
                               name="Microsoft.Windows.Common-Controls"
                               version="6.0.0.0"
                               processorArchitecture="X86"
                               publicKeyToken="6595b64144ccf1df"
                               language="*"
                       />
               </dependentAssembly>
       </dependency>
       </assembly>
    
       Save the file in the application directory with the name of the 
    application
       and an extension of exe.manifest. For instance, if your application name 
    is
       "MyApp", you will name the manifest file as MyApp.exe.manifest.
    
    5. When your application runs, Windows XP looks at the application manifest
       which tells the operating system to use common controls library version 
    6.0.

  6. #6

    Thread Starter
    Addicted Member donut's Avatar
    Join Date
    Mar 2001
    Location
    London, UK
    Posts
    165
    excellent, thanks man

  7. #7
    BG
    Guest
    Thanks Kovan, You Da Man!

  8. #8

    Thread Starter
    Addicted Member donut's Avatar
    Join Date
    Mar 2001
    Location
    London, UK
    Posts
    165
    by the way, if anyone's interested, i just tried this for devenv.exe (the vs.net exe), which will make vs.net use the xp visual styles too

  9. #9
    l33t! MrPolite's Avatar
    Join Date
    Sep 2001
    Posts
    4,428
    I didnt get what you mean "donut" what about devenv.exe? doesnt that just run VS.NET? what does it have to do with XP style then?

  10. #10

  11. #11

    Thread Starter
    Addicted Member donut's Avatar
    Join Date
    Mar 2001
    Location
    London, UK
    Posts
    165
    "MrPolite" , what i mean is that the vs.net IDE uses the windows classic style by default (ie. blocky grey buttons, etc.), but using the xml code that kovan supplied, you can make it use xp visual styles.

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