Sign in to follow this  
Followers 0
mattschinkel

Why can't I make a GUI that is 70 pix wide?

5 posts in this topic

Why can't i make this gui 70 pixles wide? I do not want any minimize/maximize/close bottons.

If I remove the gui style I can make it 70 pix wide.

#####################################################

#include <GUIConstants.au3>

#include <WindowsConstants.au3>

$gui = GUICreate("MyGUI", 70, 50, -1, -1, $WS_CAPTION)

GUISetState()

While 1

$gm = GUIGetMsg()

Switch $gm

Case $GUI_EVENT_CLOSE

ExitLoop

EndSwitch

WEnd

Share this post


Link to post
Share on other sites



it works fine for me

Share this post


Link to post
Share on other sites

Check again please.

It is more then 70 pixles. I cannot make it any less then whatever it is now. Try to make it 20 or 50 pixles wide, it will not change.

Share this post


Link to post
Share on other sites

Why can't i make this gui 70 pixles wide? I do not want any minimize/maximize/close bottons.

If I remove the gui style I can make it 70 pix wide.

#####################################################

#include <GUIConstants.au3>

#include <WindowsConstants.au3>

$gui = GUICreate("MyGUI", 70, 50, -1, -1, $WS_CAPTION)

GUISetState()

While 1

$gm = GUIGetMsg()

Switch $gm

Case $GUI_EVENT_CLOSE

ExitLoop

EndSwitch

WEnd

It's just the minimum width Windows has for the WS_CAPTION style, so there is enough room for the buttons I guess. If you add the extended style $WS_EX_TOOLWINDOW you can make a window with a caption much smaller.

$gui = GUICreate("MyGui", 40, 50, -1, -1, $WS_CAPTION,$WS_EX_TOOLWINDOW )


Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.

Share this post


Link to post
Share on other sites

Awsome.. That works great!

Thanks!

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