Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening a browser session from a VBA Script 1

Status
Not open for further replies.

Daedelus

Technical User
Aug 14, 2002
70
US
How can I open a browser and follow a link from a VBA script, and control the size and position of the browser window?

I have an Excel spreadsheet application that organizes data in the spreadsheet for entry into a form on our Intranet. I would like to have it not only organize the data, but also open a browser window sized so that I can still see the data, and link to the site where it needs to be entered.

The only way I have figured out to open the browser and go to the site is to follow a hyperlink. But this does not give me any means (that I know of) to control the browser window size and location. Every time I do this, I have to resize and relocate the browser.
 
Hi Daedalus,

In a VBA module try:

Dim IE
Set IE = CreateObject("InternetExplorer.Application")
IE.Left = 50
IE.Top = 50
IE.Height = 510
IE.Width = 470
IE.MenuBar = 0
IE.Toolbar = 1
IE.navigate "IE.Visible = 1

Ilse
 
Thanks! Is there any way to direct a text stream to the webpage? (I would like to automatically enter data into the entry fields.)
 
Hi Daedelaus,

Sorry, I do not know. Perhaps you can post your question at the VBA forum, maybe one of the gurus over there can help.

Ilse
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top