I'm trying to read a CSV file from a webpage.
I've wrote two programs (with the help of this site), Read1 and Read2. (see below)
Read1 works but puts the data in one field.
Read2 is some code which unfortunatly doesn't work.
Which code should I use if I want to import CSV-data from a website?
Thankx in advance
Sub read1()
With ActiveSheet.QueryTables.Add(Connection:="URL; _
Destination:=Range("a1"))
.Refresh BackgroundQuery:=False
.SaveData = True
End With
End Sub
Sub read2()
Workbooks.OpenText Filename:="Connection:=URL; _
DataType:=xlDelimited, Semicolon:=True
End Sub
I've wrote two programs (with the help of this site), Read1 and Read2. (see below)
Read1 works but puts the data in one field.
Read2 is some code which unfortunatly doesn't work.
Which code should I use if I want to import CSV-data from a website?
Thankx in advance
Sub read1()
With ActiveSheet.QueryTables.Add(Connection:="URL; _
Destination:=Range("a1"))
.Refresh BackgroundQuery:=False
.SaveData = True
End With
End Sub
Sub read2()
Workbooks.OpenText Filename:="Connection:=URL; _
DataType:=xlDelimited, Semicolon:=True
End Sub