mitchito Posted February 24, 2012 Posted February 24, 2012 Hi!! How ca I unable a button after pushing it? I have looked for it but I can't find it. Is it possible with AutoIt?? Thanks!!
UEZ Posted February 24, 2012 Posted February 24, 2012 What is a unable button? Do you mean enable a button? And are you talking about your own GUI or from an application's GUI? Br, UEZ Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ
mitchito Posted February 24, 2012 Author Posted February 24, 2012 Sorry for my English, I would like to unenable a button (you know, when it turns grey and you can't push it anymore) wich is in my GUI after pushing it
UEZ Posted February 24, 2012 Posted February 24, 2012 Something like this: #include <GUIConstantsEx.au3> $Form1 = GUICreate("Form1", 196, 163) $idButton_Test = GUICtrlCreateButton("Test", 40, 16, 115, 81) $idButton_Enable = GUICtrlCreateButton("Enable", 8, 128, 75, 25) $idButton_Disable = GUICtrlCreateButton("Disable", 112, 128, 75, 25) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $idButton_Enable GUICtrlSetState($idButton_Test, $GUI_ENABLE) Case $idButton_Disable GUICtrlSetState($idButton_Test, $GUI_DISABLE) Case $idButton_Test MsgBox(0, "Test", "Test button was pressed!") EndSwitch WEnd Br, UEZ Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ
mitchito Posted February 24, 2012 Author Posted February 24, 2012 OK!! Perfect that's it! GUICtrlSetState($idButton_Test, $GUI_DISABLE)I thought it was unenable sorry
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