Sign in to follow this  
Followers 0
unknown12

$GUI_EVENT

9 posts in this topic

Is there anything like $GUI_EVENT_CLOSE for when the window is maximized?

Also how can I get the with and height of a GUI item?

Share this post


Link to post
Share on other sites



HI,

WinGetState()? Maybe showing your code could help.

So long,

Mega


Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Share this post


Link to post
Share on other sites

WinGetState()? Maybe showing your code could help.

Surely you mean WinGetPos


Get Beta versions Here Get latest SciTE editor Here AutoIt 1-2-3 by Valuater - A great starting point.

Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

Surely you mean WinGetPos

Edit:

Time to get off this thing, I totally misread what this thread was asking.

Edited by SmOke_N

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

Might work

#include <GUIConstants.au3>
; == GUI generated with Koda ==
$Form1 = GUICreate("AForm1", 622, 441, 192, 125,$WS_MAXIMIZEBOX)
GUISetState(@SW_SHOW)
While 1
    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
        ExitLoop
    Case $msg=$GUI_EVENT_MAXIMIZE
        MsgBox(0,0,"MAXIMIZED")
    EndSelect
WEnd
Exit

My Scripts:Radioblog Club Music DownloaderOther stuff:Fun movieIm serious read the help file it helps :PFight 'Till you drop. Never stop, You Cant give up. Til you reach the top Fight! you’re the best in town Fight!

Share this post


Link to post
Share on other sites

Thanks!

What about getting the size of a GUI element? Eg. a group

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

ControlGetPos("", "", $controlid)

it'll return an array as follows:

$av[0] = x

$av[1] = y

$av[2] = width

$av[3] = height

:)

Edited by CHRIS95219

Share this post


Link to post
Share on other sites

One more question, looked in helpfile couldnt see. How would I Adjust width + height of a gui element?

Share this post


Link to post
Share on other sites

Guictrlsetpos

Controlmove can move a control and adjust the width and height


My Scripts:Radioblog Club Music DownloaderOther stuff:Fun movieIm serious read the help file it helps :PFight 'Till you drop. Never stop, You Cant give up. Til you reach the top Fight! you’re the best in town Fight!

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