http获取vb6并接收xml数据 [英] http get in vb6 and receive xml data

查看:149
本文介绍了http获取vb6并接收xml数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对vb6知之甚少.我有问题
我需要向服务器发出http get请求,并且响应将是一些xml数据.我还必须通过查询字符串向服务器发送一些数据.我是vb6的新手,对此一无所知.需要您的帮助.

I don't know much thing in vb6. I have a problem
I need to make a http get request to a server, and the response will be some xml data. i also have to send some data to server via query string. I'm new to vb6 and don't have any idea about how to do that. need your help.

推荐答案

您最好的选择是使用DOMDocument类,该类应该适用于从2000到7的所有Windows版本.添加对"Microsoft Xml"版本的引用

Your best bet is using the DOMDocument class, which should be on all versions of Windows from 2000 to 7. Add a reference to a version of "Microsoft Xml".

Dim oDocument As MSXML2.DOMDocument

Set oDocument = New MSXML2.DOMDocument
oDocument.Load "http://xmlserver.domainname?myQueryString"

Do Until oDocument.readyState = 4
    DoEvents
Loop

Parse(oDocument.DocumentElement)
DisplayXml(oDocument.Xml)

这篇关于http获取vb6并接收xml数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆