Wrox Programmer Forums
|
Pro VB 6 For advanced Visual Basic coders working in version 6 (not .NET). Beginning-level questions will be redirected to other forums, including Beginning VB 6.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 6th, 2006, 11:10 AM
Authorized User
 
Join Date: Feb 2005
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default system colours

Hi

The system colours on my app tend to be different based on the machine the app is running and therefore field/label backgrounds can be different colours from the main form. Al the way through the app system colours are used eg vbButtonFace, vbWindowBackground etc and to go through the whole app and hard code the colours would be a bit of a pain, is there anyway to set the system colours on loading the app ?

Regards

Daz

 
Old December 6th, 2006, 11:23 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,189
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

hi there..

are you sure you want to change the system colors of the user?? the way the user have it make usually good for them.. I think you should change your app. color to avoid any problem...

HTH

Gonzalo
 
Old December 6th, 2006, 12:07 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 627
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I do not understand the problem. if you use system colors in your app (like vbButtonFace, that BTW are all set by default in VB when a component is created) you app SHOULD run with the current selected system colors.
Can you give an example of your problem?
 
Old December 7th, 2006, 06:22 AM
Authorized User
 
Join Date: Feb 2005
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi

After further checking it seems that somebody decided to define a new set of constants for colours, hard coded to the colours they had in their user profile. At various points they used the system defaults and other points the constants. I was searching for standard vb colours and not finding any (eg the background was the same as vbgray so search the app for vbgray) therefore I though I had a problem.

Eventually tucked away in a module (obscurely named) I found the constants and assigned them to system defaults and now the form colours seem to behave correctly (with the exception of some forms that have colours assigned from the user palette rather that the system pallet)

Thanks for your responses.

Daz







Similar Threads
Thread Thread Starter Forum Replies Last Post
List Box Colours Brendan Bartley Access 1 September 26th, 2007 10:16 AM
alternating colours ozPATT Excel VBA 3 October 5th, 2005 10:19 AM
how to highlight in three colours? have code but gilgalbiblewheel Classic ASP Databases 3 October 2nd, 2004 11:04 AM
Button Colours interrupt Javascript How-To 7 August 26th, 2004 04:57 PM
How Do I Print Table Cell Colours? Lucy HTML Code Clinic 4 December 3rd, 2003 12:35 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.