Valuex
Valuex

Reputation: 126

Automate Save As File with IUIAutomation in Internet Explorer 9+

There are 63 entries on Stack Overflow related to "IE VBA Save-as" topic.
That is to automate the Download Notification Bar of IE 9+.

Several methods are recommended to automate this process.
Method 1. using XMLHttp (example link, applied to sites that show the direct url of to-be-downloaded file)
Method 2. using autoitx.dll to send hotkeys (example link, not so stable based on my experience)
Method 3. using IUIAutomation (blogspot link )

I think Method 3 is suitable for most of these situations. However, I have NOT successfully tried this method, because 1) I can't add reference to UIAutomationCore.dll I get this dll under C:\Windows\SysWOW64 and the project(*.xlsm) folder
Question1:Please tell me how to add reference to UIAutomationCore.dll.

2) Subroutine Download_Save_As in the page (blogspot link ) uses sending shortkeys to navigate to the save-as window.
I don't thinks this is stable enough as I tried the AutoitX way.
Question2:Is it possible to click the save-as option by using purely IUIAutomation way? and how to?

Upvotes: 0

Views: 1567

Answers (1)

Jason
Jason

Reputation: 1

You have to find the file in reference library and move it where it is looking. You can hover on a reference to see where they are kept. I don't know why this particular reference's location is different.

Upvotes: 0

Related Questions