尝试使用IE下载窗口(使用AutoId)保存文件,但未执行任何操作。我认为我的代码可以处理位于底部“打开/保存/取消”以下载文件的弹出选项卡,但是我看到了“查看下载-Internet Explorer”窗口,该窗口显示了我要下载的所有文件,而不是位于底部的选项卡。
有没有一种方法可以查看IE底部的选项卡,而不是查看下载窗口。我尝试了IE中的所有设置,但仍然不断弹出视图下载窗口。
任何建议我该怎么办?
autoItObj.sleep(5000);
autoItObj.controlSend(hIE ,"",hCtrl,"{F6}") ; //Gives focus to Open Button
autoItObj.sleep(500);
autoItObj.controlSend(hIE ,"",hCtrl,"{TAB}") ; //Gives focus to Save Button
autoItObj.sleep(500);
autoItObj.controlSend(hIE ,"",hCtrl,"{DOWN}") ; //Opens Save options
autoItObj.sleep(500);
autoItObj.controlSend(hIE ,"",hCtrl,"{DOWN}") ; //Gives focus to Save As
autoItObj.sleep(500);
autoItObj.controlSend(hIE ,"",hCtrl,"{enter}") ; //Submit whatever control has focus
autoItObj.sleep(10000);
autoItObj.sleep(5000);
autoItObj.controlFocus("Save As","","Edit1");
String testSaveHndl = autoItObj.controlGetHandle("Save As","","Edit1");
autoItObj.controlSend("Save As", "", "[CLASS:Edit; INSTANCE:1]", fullpath);
autoItObj.sleep(10000);
autoItObj.controlClick("Save As", "", "Button2");
autoItObj.sleep(1000);