RE: Internet Table Transfer
- From: John.Greenan <JohnGreenan@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 3 May 2006 08:03:02 -0700
There's a thread on here at
http://msdn.microsoft.com/newsgroups/default.aspx?dg=microsoft.public.excel.programming&mid=fb6f2c66-6841-4617-8c24-a6a382460127&sloc=en-us
that does something similar. It also uses the Windows API.
--
www.alignment-systems.com
"MBSNewbie" wrote:
Hi Everyone,.
Does anyone have any experience trying to retreive data from the web into
Excel without using web query?
I've been trying for a few weeks and can only get as far as Excel Data into
the Internet, I manually select the data and copy then resume the macro.I'm
not sure how to get the info from the Internet into Excel. I'm not using any
add-ins. I hope this clarifies my earlier question, but I'm crunched for
time and I'm hoping there is someone out there who can help me.
Thanks!!!
Const url As String =
"https://www65.americanexpress.com/opm/en_US/ViewStatement"
Dim ie As Object, sampleData(1 To 2) As String, cTables As Object, X As
Integer
Dim MyArr As Variant, cl As Range, y As Work***, Account As String
'///Setting
For Each cl In Range([a2], [a33].End(3))
Account = cl.Value
Set ie = CreateObject("internetexplorer.application")
With ie
Dim ws As Work***
Dim newSheetName As String
.Visible = True
.navigate url
Do While .ReadyState <> 4:
Loop
'///Send data to IE
With .Document.all
.acct.Value = Account
.submit1.Click
Do While ie.ReadyState <> 4:
Loop
End With
End With
Sheets.Add Type:="Worksheet"
With Active***
.Move After:=Worksheets(Worksheets.Count)
.Name = cl.Value
End With
X = 1
For X = 1 To 10
Answer = MsgBox("Would You Like To Paste?", vbYesNo)
If Answer = vbYes Then
Active***.Paste
ActiveCell.SpecialCells(xlLastCell).Select
Else:
Cells.Select
With Selection
.WrapText = False
.Orientation = 0
.AddIndent = False
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = False
End With
Cells.EntireColumn.AutoFit
Cells.EntireRow.AutoFit
Range("A1").Select
Exit For
End If
Next X
Next
End Sub
- References:
- Internet Table Transfer
- From: MBSNewbie
- Internet Table Transfer
- Prev by Date: Re: How to load Excel startup files through code
- Next by Date: RE: VBA and SQL dump changing the cell types in other worksheets
- Previous by thread: RE: Internet Table Transfer
- Next by thread: QueryTable date problem
- Index(es):