Zealot Posted February 4, 2008 Posted February 4, 2008 Hello, I'm trying to get a checkbox to float above a button. I used GUICtrlSetState with $GUI_ONTOP on the checkbox, and it enables the box to be checked, but it doesn't keep it visible. Am I doing something wrong, or can anyone point out an alternate way? Thanks, Simon Example code: #include <GUIConstants.au3> ; Define the GUI $GUIHandle= GUICreate("Button-Checkbox Experiment", 574, 469, -1, -1) $Button= GUICtrlCreateButton("Button", 10, 10, 100, 25) $Checkbox= GUICtrlCreateCheckbox("", 85, 15, 15, 15) GUICtrlSetState($Checkbox, $GUI_ONTOP) $OutputWindow= GUICtrlCreateEdit("", 10, 120, 300, 300) GuiSetState () ; Run the GUI until the dialog is closed While 1 $msg = GUIGetMsg() Select Case $msg = $Button GUICtrlSetData($OutputWindow, "Button" & @CRLF & GUICtrlRead($OutputWindow)) Case $msg = $Checkbox GUICtrlSetData($OutputWindow, "Checkbox" & @CRLF & GUICtrlRead($OutputWindow)) EndSelect If $msg = $GUI_EVENT_CLOSE Then ExitLoop Wend
Siao Posted February 4, 2008 Posted February 4, 2008 Give the button $WS_CLIPSIBLINGS style. "be smart, drink your wine"
Zealot Posted February 5, 2008 Author Posted February 5, 2008 Give the button $WS_CLIPSIBLINGS style.Thank You!Z
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now