When using the wpf elements of my application, everything styles to the operating system, but when I use an OpenDialog or a MessageBox, it renders the older Windows 9X way. Is there an easier way I can do an Application.EnableVisualStyles() equivalent call to make the message boxes and dialogs look the same as the rest of the application?
+3
A:
This blog post may be worth a look:
Why does the OpenFileDialog in WPF look so “1999” and how can I fix it?
Tormod Fjeldskår
2009-04-22 19:50:22
+5
A:
You need to add a manifest to your assembly. You can do this via Add New Item-->General-->Application Manifest file.
Then add the following somewhere inside the asmv1 tag in the manifest file:
<dependency>
<dependentAssembly>
<assemblyIdentity name="Microsoft.Windows.Common-Controls" version="6.0.0.0" type="win32" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*" />
</dependentAssembly>
</dependency>
Botz3000
2009-04-22 19:58:00
Thanks Botz3000! This solution worked great.
Mel Green
2009-05-06 22:16:20