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 biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IE Via Excel VBA

Status
Not open for further replies.

mustangcoupe

Technical User
Feb 26, 2003
221
US
I am looking to use VBA in excel to post some information in an html format.

That part I have down. But I also need to open an IE window and display this information and then refresh the window everytime the data is updated.
ex. the user is going to input the information in a user box in excel and click "submit changes"(command box) and this will trigger a sequence of events which will export a workbook page in a html format.

How do I open IE to a specific webpage from the shell command? or isnt that the best way to do it...

and how do I refresh the IE page say when command button 2 is pressed?.

thanks
 
I have answered my own questions. for those of you who might be interested I used the following work around.

I used the following to publish sheet3 in my workbook to my hard drive

ActiveWorkbook.PublishObjects.Add(xlSourceSheet, "C:\doc.html", "Sheet3", "", _
xlHtmlStatic, "Book1_10748", "").Publish (True)
ChDir "C:\"

then used
Set wShell = CreateObject("Shell.Application")
wShell.Open "c:\doc.html"
to open the ie window

and later in my code I used
AppActivate "Microsoft Internet Explorer", 1
to select the IE window.
then used
SendKeys "{F5}"
to refresh the window.

If anyone has an easier way to do this let me know...

Todd
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top