|
-
Apr 16th, 2004, 04:06 AM
#1
Thread Starter
Hyperactive Member
determine windowing style *RESOLVED!*
hey.
how can i determine, via vb.net code, if a user has xp style enabled on their desktop? Easy enough to determine OS version, but what about xp style?
thanx.
Last edited by jovton; Apr 24th, 2004 at 03:31 AM.
jovton
-
Apr 16th, 2004, 06:10 AM
#2
Fanatic Member
why u need to do that? i mean, what's the purpose?
i think the style may not be the static property of the OS for one PC as it may vary from user to user.
-
Apr 16th, 2004, 10:25 AM
#3
Originally posted by pvbangera
why u need to do that? i mean, what's the purpose?
i think the style may not be the static property of the OS for one PC as it may vary from user to user.
There could be several reasons. I'd like to know too.
When developing visual ownerdrawn controls it would be nice if the control automatically follows the theme.
So for that reason it would be nice to know if the styles are used or not, and if they are, which one. (not considering custom styles, but only the built-in styles)
They way I do it at the moment, is checking the RGB values of systemcolor.activecaption. This colour is unique for LunaBlue, OliveGreen and Silvergrey. If the color doesnt match any of these three, I assume styles aren't used.
But this method isn't very reliable, because the user could easily have changed this color or the user could be using a custom theme with a totally different colorscheme.
I wish I could think of something witty to put in my sig...
...Currently using VS2013...
-
Apr 23rd, 2004, 05:06 AM
#4
Hi.
Found it.
You can look in the registry.
If you run RegEdit and browse to the following key, you find all the info you need : HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\ThemeManager
Then it's just a matter of looking up the ThemeActive value thru VB.
I hope this helps you. I know it helps me..
I wish I could think of something witty to put in my sig...
...Currently using VS2013...
-
Apr 24th, 2004, 03:29 AM
#5
Thread Starter
Hyperactive Member
Geeee. Thanks. What do I owe you?
Last edited by jovton; Apr 24th, 2004 at 03:34 AM.
jovton
-
Apr 24th, 2004, 05:33 AM
#6
I wish I could think of something witty to put in my sig...
...Currently using VS2013...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|