Jump to content

Recommended Posts

I expected it only sets the color for text written after it is called. This one work-around I guess.

Opt('MustDeclareVars', 1)

Local $hGUI = GUICreate("Test")
GUICtrlSetDefColor(0xFF0000, $hGUI)

GUICtrlCreateLabel("Label", 10, 10, 100, 20)
Local $button = GUICtrlCreateButton("Button", 10, 50, 100, 50)

GUISetState()
While 1
    Switch GUIGetMsg()
        Case -3
            Exit
        Case $button
            ConsoleWrite(GUICtrlSetDefColor(0x0000FF, $hGUI) & @CRLF)
            GUICtrlCreateLabel("Label", 10, 10, 100, 20)
    EndSwitch
WEnd

- Bruce /*somdcomputerguy */  If you change the way you look at things, the things you look at change.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...