Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Wait button clickable
#2
try using wait for window enabled
here is a basic example using a qm dialog


Function Dialog3
Code:
Copy      Help
str dd=
;BEGIN DIALOG
;0 "" 0x90C80AC8 0x0 0 0 224 136 "Dialog"
;3 Button 0x5C032000 0x0 88 56 48 14 "My Button"
;4 Button 0x54032000 0x0 8 56 60 14 "Enable MyButton"
;1 Button 0x54030001 0x4 116 116 48 14 "OK"
;2 Button 0x54030000 0x4 168 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2040700 "*" "" "" ""

if(!ShowDialog(dd &sub.DlgProc 0)) ret


#sub DlgProc
function# hDlg message wParam lParam

sel message
,case WM_INITDIALOG
,mac "sub.WaitforButtonEnabled" "" hDlg
,
,case WM_DESTROY
,case WM_COMMAND goto messages2
ret
;messages2
sel wParam
,case IDOK
,case IDCANCEL
,case 4 ;;Enable MyButton
,EnableWindow id(3 hDlg) 1 
ret 1

#sub WaitforButtonEnabled
function hwnd
int w1=wait(0 WE id(3 hwnd))
out "button enabled"

read here for how to use accessible objects  to wait for enabled button

http://www.quickmacros.com/forum/showthr...5#pid23045

You  should  probably  use accessible  objects since it appears  the button is a menu  or possibly a toolbar   button


Messages In This Thread
Wait button clickable - by win - 11-24-2018, 10:10 PM
RE: Wait button clickable - by Kevin - 11-24-2018, 11:22 PM
RE: Wait button clickable - by win - 11-25-2018, 12:19 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)