Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA update data from Internet Explorer and copy to Excel?
|
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA update data from Internet Explorer and copy to Excel?
From a previous post by Jake Marx:
http://groups.google.com/groups?selm...%40tkmsftngp05 ---------------------- From: Jake Marx ) Subject: Controlling IE5 from VBA in Excel 2000 View: Complete Thread (5 articles) Original Format Newsgroups: microsoft.public.excel.programming Date: 2001-07-12 20:23:59 PST Hi George, Here's a function that will grab the text of a web page for you: Function sGetURLText(sURL As String) As String Dim ie As Object Set ie = CreateObject("InternetExplorer.Application") ie.Navigate sURL Do Until ie.ReadyState = 4 DoEvents Loop sGetURLText = ie.Document.Body.InnerText If InStr(1, sGetURLText, "The page cannot be displayed", _ vbTextCompare) Then sGetURLText = "" ie.Quit Set ie = Nothing End Function Just pass in the URL as an argument, and the function will return either an empty string (invalid URL) or the text of the page. Hopefully this will do what you were looking for. Regards, Jake Marx --------------------- Regards,Tom Ogilvy"Mauricio Harger" wrote in message ... Hi, I would like to update data from the internet automatically with VBA. I have already automated opening IE in the correct link with VBA. Now I need to find the data (it is sometimes in different place) and copy to excel. Does anybody has a routine to do it? Thanks, -- Mauricio Harger - Brazil |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Internet Explorer 7 & Excel 2000 | Excel Discussion (Misc queries) | |||
How do I view Excel data in Internet Explorer? | Excel Discussion (Misc queries) | |||
Launching Excel From internet Explorer | Excel Discussion (Misc queries) | |||
Internet Explorer opens a local copy | Excel Discussion (Misc queries) | |||
Running Internet Explorer from Excel | Charts and Charting in Excel |