Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 73
Default Automate IE right-click "Save Target As..."

Anyone who might know:

I am able to do limited work in automating IE via VBA. I am able to
navigate to a website, select radio and option buttons, click links,
and submit a form. If the form returns the request as HTML within the
IE window I can pull off the information from IE and dump it into
Excel. (I use something like "SetText ie.document.innerHTML" and then
pull it off the clipboard).

The website that I'm now accessing requires a username and password.
I can get into the site via VBA and navigate to where I want and
submit the form; however, my data now comes over according to a
selected option. I can select the output as *.txt or *.csv. Since
the website does not automaticaly load the data into the IE window as
HTML I can't simply use the .innerHTML option.

If I select the *.txt or *.csv output option and submit the form the
output is returned in the IE window as a link. I can then
programmatically click the link.

If the output option is *.txt and I click the link, the text file is
opened in the IE window. However, because it does not have a HTML
format I cannot use .innerHTML to copy the data over.

How can I programmatically get the text off of IE and into Excel?

Additionally, I'm wondering how to programmatically right-click the
link and select the "Save Target As..." option. I could select the
output option as *.csv and then save the target. I could then use VBA
to then open the *.csv file and copy the data over. Since the website
requires a username and password a simple Workbooks.Open
Filename:=http:... will not work.

How can I programmatically perform the right-click "Save Target As..."
option via VBA?

Thanks in Advance,

Matt

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
"Save" and "Save As" options greyed out - "Save as Webpage" option Bill Excel Discussion (Misc queries) 0 January 16th 07 04:47 PM
"Control" plus "click" doesn't allow me to select multiple cells Ken Cooke New Users to Excel 0 September 25th 06 04:46 PM
Automatically click "Update Links" & "Continue" paulharvey[_13_] Excel Programming 0 June 3rd 06 05:35 PM
Worksheets("Brackets").DropDowns("Game10").Click Tony_VBACoder Excel Programming 5 January 28th 05 04:41 AM
VBA Code to automate "Save As" Kevin McLean Excel Programming 3 September 25th 03 11:56 PM


All times are GMT +1. The time now is 08:50 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"