mr-es335 Posted November 1, 2023 Share Posted November 1, 2023 Good day, Is there any way - again a neophyte here...to have this script employ/call a function? ; ----------------------------------------------- #include <AutoItConstants.au3> #include <FontConstants.au3> #include <GUIConstantsEx.au3> ; ----------------------------------------------- Local $hGUI=GUICreate("Title", 360, 215) GUISetFont(12, $FW_BOLD, $GUI_FONTNORMAL, "Calibri") Local $MyButton=GUICtrlCreateButton("Variable", 20, 20, 150, 25) ; ----------------------------------------------- GUISetState(@SW_SHOW, $hGUI) ; ----------------------------------------------- While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE, $MyButton ExitLoop EndSwitch WEnd ; ----------------------------------------------- Thanks! mr-es335 Sentinel Music Studios Link to comment Share on other sites More sharing options...
Solution Andreik Posted November 1, 2023 Solution Share Posted November 1, 2023 #include <AutoItConstants.au3> #include <FontConstants.au3> #include <GUIConstantsEx.au3> ; ----------------------------------------------- Local $hGUI=GUICreate("Title", 360, 215) GUISetFont(12, $FW_BOLD, $GUI_FONTNORMAL, "Calibri") Local $MyButton=GUICtrlCreateButton("Variable", 20, 20, 150, 25) ; ----------------------------------------------- GUISetState(@SW_SHOW, $hGUI) ; ----------------------------------------------- While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE ExitLoop Case $MyButton MyFunc() EndSwitch WEnd Func MyFunc() MsgBox(0, '', 'Yayyy') EndFunc mr-es335 1 When the words fail... music speaks. Link to comment Share on other sites More sharing options...
mr-es335 Posted November 2, 2023 Author Share Posted November 2, 2023 Andreik, Thanks...appreciated! • Works like a charm! mr-es335 Sentinel Music Studios Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now