Parse data from HTML

G

Guest

I have this code to import comma delimited data from a website. This code
gets the data and I can display it in a message box , but I can't figure out
how to get the data (from ResponseText) into a table. Any ideas?

Thanks. Paco

Dim objHttp As Object
Set objHttp = CreateObject("MSXML2.ServerXMLHTTP")
Call objHttp.Open("GET", "URL", False)
Call objHttp.send("")
Call MsgBox(objHttp.ResponseText)
 
P

Pieter Wijnen

not familiar with MSXML2.ServerXMLHTTP
but you can assign the text to a string variable & write it to a local file
using
open "C:\MyFile.txt" For Output As 1
print #1, txt
close #1

then use docmd.transfertext

hth

Pieter
 
G

Guest

With some other code, that's what I am doing now (saving a file and then
using TransferText). I'm trying to avoid creating a file. If ResponseText can
be displayed in a message box, it seems like there should be a way to parse
it and import it into a table directly.
 
P

Pieter Wijnen

offcourse
but you'd have to program it all by yourself AFAIK & AFAI i've experienced

Pieter
 

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