Jump to content

Recommended Posts

Posted

Hi to all

 

I have i bit of i question.

 

If i use the Koda from autoIt i cREATE my own GUI example

 

 

#include

#include

#include

#Region ### START Koda GUI section ### Form=

Global $Form1 = GUICreate("Form1", 288, 106, 192, 124)

Global $Button1 = GUICtrlCreateButton("Button1", 16, 24, 249, 49)

GUISetState(@SW_SHOW)

#EndRegion ### END Koda GUI section ###

 

While 1

$nMsg = GUIGetMsg()

Switch $nMsg

Case $GUI_EVENT_CLOSE

Exit

 

Case = $nMsg

MsgBox(0, "", "Dialog was closed")

 

 

EndSwitch

WEnd

 

 

 

 

I only added the part

 

Case = $nMsg

MsgBox(0, "", "Dialog was closed")

 

Where is my problem can somebody please Help

 

Tanx

  • 2 months later...
Posted

Not really sure as what you have got looks OK, however when I use "Case" statements in AutoIt, I generally use them under the "Select" context, rather then the "Switch" context.

 

So try changing

 

Switch $nMsg

 

for

 

Select

 

Case xxx

 

Case yyy

 

Case zzz

 

EndSelect

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



  • 11 When would you like EduGeek EDIT 2025 to be held?

    1. 1. Select a time period you can attend


      • I can make it in June\July
      • I can make it in August\Sept
      • Other time period. Please comment in the thread what works for you
      • Either time

×
×
  • Create New...