Sign in to follow this  
Followers 0
bobheart

How to remove the max/min box

3 posts in this topic

How do you remove or gray out the max/min box so the gui can't be made bigger /smaller ?

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

If you do not specify a style when you call GUICreate, it uses 0x94CA0000 which makes the window not resizable. (Frame cannot be resized, maximize button is grayed-out, but you can still minimize and close.)

GuiCreate("Sample", 100, 100, 50, 50)
GuiWaitClose()

I have a partial list of useful GUI Window styles somewhere on my computer .... *Eventually* I hope to submit it for the documentation.

I'm not sure about disabling the minimize button. Valik or others probably know. Here's a workaround:

$title = "SampleFoo"
GuiCreate($title, 100, 100, 50, 50, 0x94CA0000)
GuiShow()

While 1
   sleep(100)
   $msg = GuiMsg(0)
   If $msg = -3 Then Exit
   If $msg = -4 Then WinSetState($title,"",@SW_RESTORE)
WEnd
Edited by CyberSlug

Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!

Share this post


Link to post
Share on other sites

Thank you , using 0x94CA0000 did the trick .

Share this post


Link to post
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
Sign in to follow this  
Followers 0