Auf Label klicken

  • Hi,
    gibt es eine Abfrage, ob in einem GUI auf ein Label geklickt wurde? Z.B. Klicke ich mit der Maus ganz gewöhnlich auf den Text und es erscheint ein neues GUI. Im Grunde wie ein Button, nur ohne den Button^^
    Ich hoffe ihr könnt mir weiterhelfen.
    Aquaplant

    Einmal editiert, zuletzt von Aquaplant (23. Dezember 2009 um 16:23)

  • Bsp:

    Spoiler anzeigen
    [autoit]


    #include <GUIConstantsEx.au3>

    [/autoit] [autoit][/autoit] [autoit]

    Opt('MustDeclareVars', 1)

    [/autoit] [autoit][/autoit] [autoit]

    Example()

    [/autoit] [autoit][/autoit] [autoit]

    Func Example()
    Local $widthCell, $msg, $iOldOpt, $1

    [/autoit] [autoit][/autoit] [autoit]

    GUICreate("My GUI") ; will create a dialog box that when displayed is centered

    [/autoit] [autoit][/autoit] [autoit]

    GUISetHelp("notepad") ; will run notepad if F1 is typed
    $iOldOpt = Opt("GUICoordMode", 2)

    [/autoit] [autoit][/autoit] [autoit]

    $widthCell = 70
    $1= GUICtrlCreateLabel("Line 1 Cell 1", 10, 30) ; first cell 70 width

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    GUISetState() ; will display an empty dialog box

    [/autoit] [autoit][/autoit] [autoit]

    ; Run the GUI until the dialog is closed
    while 1
    $msg = GUIGetMsg()
    Switch $msg
    case $GUI_EVENT_CLOSE
    exit
    case $1
    MsgBox(1, "", "Label geklickt")
    EndSwitch
    wend
    $iOldOpt = Opt("GUICoordMode", $iOldOpt)
    EndFunc ;==>Example

    [/autoit]