MFC background color problems

Hi

i've got quite some trouble with making my MFC dialog looking better..

first: how do i change the dialog's background color at runtime?

It works with SetDialogBGColor() in the InitInstance, but how do i do it for example when i hit a button?



second: how do i change the background color of a CTab control? when i change the dialog bg color the Tab stays at the grey system color and only the rest of the dialog has the other color


Comments

  • Just call that function when a "button" is pressed,

    double click on a button and then a dialog coming up ande the function name is

    there, click OK and you can edit the code for clicking that button! :)



    void CMyDlg::OnButton1Click()

    {

    SetB..(RBG(0,0,0,));

    //or something like that

    }



    hope this work!


  • nope,

    SetDialogBGColor() is a protected member function od CWinApp so i have no access to it outside the InitInstance function =(


  • hmm.... send me an e-mail from you...

    so that we can talk that way...

    I realy can help you!



    do you have ICQ?

    send to: nikado@pc.nu





    : nope,

    : SetDialogBGColor() is a protected member function od CWinApp so i have no access to it outside the InitInstance function =(

    :






Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories