grabbing data off web pages using excel macro
grabbing data off web pages using excel macro
(OP)
I can easily grab a web page and put it into Excel, if I know the URL.
I want to 'construct' the URL using the
ActiveWorkbook.Worksheets.Add
With ActiveSheet.QueryTables.Add(Connection:="URL;http://www.???????
function.
VB doesn't apparently parse a variable within this command - so I can't write this as Add(Connection:= and then use a variable.
Is there a workaround?
If I knew where the macro scripts are located I could write the macro 'on the fly' then call it but I suspect that the macros are all scrunched up in a file somewhere and maybe not accessible.
Or maybe there's another command designed to accept parameters within it?
Thanks in advance...
I want to 'construct' the URL using the
ActiveWorkbook.Worksheets.Add
With ActiveSheet.QueryTables.Add(Connection:="URL;http://www.???????
function.
VB doesn't apparently parse a variable within this command - so I can't write this as Add(Connection:= and then use a variable.
Is there a workaround?
If I knew where the macro scripts are located I could write the macro 'on the fly' then call it but I suspect that the macros are all scrunched up in a file somewhere and maybe not accessible.
Or maybe there's another command designed to accept parameters within it?
Thanks in advance...
RE: grabbing data off web pages using excel macro
Hi.
Why did you ask this question in this Attachmate forum?
This is a forum707: VBA Visual Basic for Applications (Microsoft) question.
However a solution..
CODE
With ActiveSheet.QueryTables.Add(Connection:="URL;http://www." & YourVariable & ")"
Skip,
Just traded in my old subtlety...
for a NUANCE!