Save web page as desktop file from Excel/VBA

E

ExcelMonkey

I know that I can save a web page as a file on my desktop by foing Sav
As and choosing the destination

I want to be able to (in Excel/VBA) save it as a file repeatedly ove
several time increments (using the OnTime method). Each time it save
I want it to replace the previous version of the file. How do I d
this?

Thank-you
 
M

Mark

Hi,
If you already have the code but are intercepted with
the "do you want to replace" box then use the sendkeys
method to say "yes". Sendkeys initializes before the event.

assuming the "Yes" button is the focus then:

sendkeys ~
filesaveas filename:"xxx"


if the focus is on the "No" which it usually is then you
have to tab over to yes.


sendkeys (TAB)
sendkeys ~
filesaveas filename:"xxx"


regards
Mark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top