steva
asked on
Changing the Dialog Box background color
I've created a dervied CStatic class that has methods to set the text color and text background color for any text written into the Static Text box. This works fine, but how can I change the background color of the dialog box itself?
Thanks,
Steve
Thanks,
Steve
also here is simple method for you..
With the class derived from CWinApp, inside the InitInstance() try calling
'SetDialogBkColor(RGB(255, 255, 255));'
This will set your dialog box to white, you can use any colour you wish by
changing the RGB values.
MAHESH
With the class derived from CWinApp, inside the InitInstance() try calling
'SetDialogBkColor(RGB(255,
This will set your dialog box to white, you can use any colour you wish by
changing the RGB values.
MAHESH
this is good dialogbox related link..with tips..refer here abt change color n all
http://www.codeproject.com/dialog/dialog_tips.asp
MAHESH
http://www.codeproject.com/dialog/dialog_tips.asp
MAHESH
ASKER
Mahesh, thanks for the great leads. I'm sure I can get this working from something in here. But could you please provide a bit more detail about your "class derived from CWinApp" suggestion? Are you suggesting that I build a new class based on CWinApp that has a SetDialogBkColor method? How do I get this to reference my dialog box? A bit of sample code would be a big help.
Thanks,
Steve
Thanks,
Steve
class derived from CWinApp thats just for example..here is your dialog.....just write that in your dialog's InitInstance() thats all
MAHESH
MAHESH
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks Mahesh. By the way, I accidently opened this question twice. If you post a comment to the other one I'll give you those points too.
Steve
Steve
http://support.microsoft.com/default.aspx?scid=kb;EN-US;q115087
http://www.codeproject.com/dialog/ProgDlg.asp
MAHESH