[Last Call] Learn how to a build a cloud-first strategyRegister Now


Save to an XML File

Posted on 2006-05-23
Medium Priority
Last Modified: 2010-05-01
I am using VBScript.  I need to make an HTTP call to an address and save it as an XML File.  I am pretty good with VB but I have never done this before, so if someone could nudge me in the right direction it would appreciated.

Question by:99Times
LVL 44

Accepted Solution

bruintje earned 2000 total points
ID: 16746552
Hi 99Times,

you could try something like

' declare objects
Dim xmlhttp, xmldoc
' create objects
Set xmlhttp = CreateObject("MSXML2.XMLHTTP")
Set xmldoc = CreateObject("MSXML2.DOMDocument")
' put url of xml here
xmlhttp.Open "GET", "http://www.w3schools.com/xml/note.xml", False
' send the order for this file out
' put the return doc in the local xml document object
xmldoc.loadXML (xmlhttp.responseXML.XML)
' save to file
xmldoc.Save "c:\testmenow.xml"

share what you know, learn what you don't

Author Comment

ID: 16746988
that worked great.  thanks!

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question