Web Query Results to an Array

R

Raul

I can define MyURL and use the following to ge the information I need to a
worksheet. But I'd like to know what I need to do to get the same
information directly into an array.

In other words, how can I query a web page (with web parts) in VBA and put
the results into an array?

With ActiveSheet.QueryTables.Add(Connection:=MyURL,
Destination:=Range("B2"))
.Name = "Sort%20by%20PBOMP%20No"
.FieldNames = True
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = True
.RefreshOnFileOpen = False
.BackgroundQuery = True
.RefreshStyle = xlInsertDeleteCells
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = True
.RefreshPeriod = 0
.WebSelectionType = xlSpecifiedTables
.WebFormatting = xlWebFormattingNone
.WebTables = """onetidDoclibViewTbl0"""
.WebPreFormattedTextToColumns = True
.WebConsecutiveDelimitersAsOne = True
.WebSingleBlockTextImport = False
.WebDisableDateRecognition = False
.WebDisableRedirections = False
.Refresh BackgroundQuery:=False
End With


Thanks in Advance,
Raul
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top