kambodianboi Posted October 27, 2008 Share Posted October 27, 2008 Hey guys, Im trying to disable a control on the Print dialog. I created a simple script, it kinda works, but for some reason, it does not take effect when the Print window pop up. But if I click outside of it, and it refocus itself, then it disable the control. #include <GUIConstantsEx.au3> If WinExists("Print") Then If ControlCommand ( "Print", "", 1153, "IsEnabled", "" ) Then ControlDisable ( "Print", "", 1153) EndIf EndIf While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop EndSelect WEnd Any help would be much appreciated Link to comment Share on other sites More sharing options...
Zedna Posted October 27, 2008 Share Posted October 27, 2008 (edited) While 1 If WinExists("Print") Then If ControlCommand ( "Print", "", 1153, "IsEnabled", "" ) Then ControlDisable ( "Print", "", 1153) EndIf EndIf Sleep(100) WEnd Edited October 27, 2008 by Zedna Resources UDF ResourcesEx UDF AutoIt Forum Search 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