c# - Handling Windows Popup like Save As, Choose File, Direct UI HWND InternetExplorer Download Strip....When System is Locked -
to handle windows popup i'd followed 3 different ways none of them works when system locked, kindly me this
with of uiautomationclient.dll,uiautomationclientsideproviders.dll,uiautomationprovider.dll,uiautomationtypes.dll
using system.windows.automation; automationelement ieelement = automationelement.fromhandle((intptr)ieobj.hwnd);//save popup handle popups automationelement saveelement = returnrequiredelement(ieelement, "save", "name"); if (saveelement.current.name.equals("save")) { var invokepattern = saveelement.getcurrentpattern(invokepattern.pattern) invokepattern; invokepattern.invoke(); }
with of inputsimulator
using windowsinput; inputsimulator.simulatemodifiedkeystroke(virtualkeycode.menu, virtualkeycode.vk_s);
with sendkeys
sendkeys.sendwait("^+{s}");
you know while running scheduler or batch process automation in system can't expect should active always, in servers
thanks in advance
Comments
Post a Comment