SweatyOgre Posted April 12, 2005 Posted April 12, 2005 I'm trying to make a GUI with a label that displays a counter of how many times an event occurs. Everything displays fine, but I want the GUI window to stay on top of all other windows, as is my understanding of what $WS_EX_TOPMOST does. The window appears, and shows the counter, but goes under other windows. Is there a problem with my code that is preventing this from happening? $style1 = BitOR($WS_POPUP, $WS_EX_TOPMOST) GuiCreate("Counter", 115, 67,(@DesktopWidth-115)/2, (@DesktopHeight-67)/2 , $style1)
jpm Posted April 12, 2005 Posted April 12, 2005 I'm trying to make a GUI with a label that displays a counter of how many times an event occurs. Everything displays fine, but I want the GUI window to stay on top of all other windows, as is my understanding of what $WS_EX_TOPMOST does. The window appears, and shows the counter, but goes under other windows. Is there a problem with my code that is preventing this from happening?$style1 = BitOR($WS_POPUP, $WS_EX_TOPMOST) GuiCreate("Counter", 115, 67,(@DesktopWidth-115)/2, (@DesktopHeight-67)/2 , $style1)<{POST_SNAPBACK}> $WS_EX_TOPMOST is an extended style NOT a style so you needGuiCreate("Counter", 115, 67-1, -1 , $WS_POPUP,$WS_EX_TOPMOST) You don't even need to compute the position of the window -1,-1 will center the window
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