Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

XP Themes, setting value on ActiveX controls

Status
Not open for further replies.

SteveDingle

Programmer
Jul 26, 2004
254
GB
Heya All (and Happy Holidays!!!!),

I currently use a few of DBI activeX controls in my framework and wanted to make them "XP Theme friendly" and they don't come with a Themes = .T. propety. Therefore I would need to set the values myself

My assumption is that I can query the OS and get the values I need but I haven't been able to find documentation that says...

ListBarBackGroundFillType = "Value I need to get"
ListBarBackGroundColor = "Value I need to get"
ListBarBackGroundColorTo = "Value I need to get"

Anyone know of a good resource (in VFPeese) for this type of info.

Also anyone know of VFP classes to get this Theme specific info already out there (save me putting something together myself) I will make something up myself if nothings out there and share of course.

Toodles,
Steve Dingle
D&S Business Solutions Ltd
 
The API function you need to read the user's colors is GetSysColor(). I wrote about it a long time ago in FPA, but that was pre-XP. However, the basic ideas should hold--you just need to find the appropriate list of constants.

Tamar
 
Heya Tamar,

Thanks for the response, I should have been a bit more specific. I was aware of GetSysColor but Themes often have gradient colors and (I think) gradients types and GetSysColor doesn't seem to provide that.

For example, I use DBI's ListBar which is similar to Outlooks list/menu bar on the left, however it doesn't support themes natively which means I have to apply all those settings myself (colors AND Fonts, Mouse pointers and sounds etc...)

So ultimately I was hoping I to find something (a class or even docs) that provides this information from a "current theme" perspective.

I'll start working on building something myself in case nothing else is available. Of course if anyone has any pointers about this, any and all feedback would be appreciated.

To be honest I'm more a "classic" windows kind guy so don't have much experience working with various themes.

Toodles,
Steve Dingle
D&S Business Solutions Ltd
 
I think GetSysColor still works and they've expanded the list of things it returns, but I'm not sure.

Tamar
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top