Jump to content

Recommended Posts

Posted

func _msgcls()

if WinExists("poop", "") = 1 Then

$msg = GUIGetMsg()

If $msg = $GUI_EVENT_CLOSE Then

GUISetState(@SW_HIDE)

EndIf

endif

endfunc

when i compile it tells me $GUI_EVENT_CLOSE isnt declared, but i dunno why i should have to declare this when its you know, $GUI_EVENT_CLOSE isnt a variable

is this a bug i found or am i doing something wrong?

Posted

$GUI_EVENT_CLOSE is a variable. This variable is defined in another file. This file is called an include. You can use includes with the #include directive. The file you need to include is called GUIConstantsEx.au3. Your code should contain this:

#include <GUIConstantsEx.au3>

And just in case you don't know, it should be at the top. Just like all the GUI examples.

Posted

func _msgcls()

if WinExists("poop", "") = 1 Then

$msg = GUIGetMsg()

If $msg = $GUI_EVENT_CLOSE Then

GUISetState(@SW_HIDE)

EndIf

endif

endfunc

when i compile it tells me $GUI_EVENT_CLOSE isnt declared, but i dunno why i should have to declare this when its you know, $GUI_EVENT_CLOSE isnt a variable

is this a bug i found or am i doing something wrong?

Hi lionfaggot,

#include-once

; #INDEX# =======================================================================================================================
; Title .........: GUIConstantsEx
; AutoIt Version : 3.2
; Language ......: English
; Description ...: Constants to be used in GUI applications.
; Author(s) .....: Jpm, Valik
; Dll ...........:
; ===============================================================================================================================

; #CONSTANTS# ===================================================================================================================
; Events and messages
Global Const $GUI_EVENT_CLOSE = -3

$GUI_EVENT_CLOSE is a Constant.

just include GUIConstantsEx.au3 and WindowsConstants.au3 as described in the help file...

Regards,

Hannes

Regards,Hannes[spoiler]If you can't convince them, confuse them![/spoiler]
Posted

now its not hiding the window, man, now im really lost, click close and its like nothing. i have include files etc

:\

There's nothing wrong with your posted code. Mostly because we don't know how you are calling the function. Post more relevant code and we can identify the problem.

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...