Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP General (http://www.velocityreviews.com/forums/f65-asp-general.html)
-   -   Simple XML Example (http://www.velocityreviews.com/forums/t795953-simple-xml-example.html)

James Baker 08-19-2004 02:03 PM

Simple XML Example
 
I have a very simple query that gets a few records from a database. I need
to take this, turn it into XML and post it to a client's website via
VBScript. I was able to find an example of exporting the data to an XML
file, but I'm lost on the syntax for actually posting the data to a third
party page. I'm sure this is simple, can someone provide me with an
example? Thanks!

Relevant code currently is:

Response.ContentType = "text/xml"

Dim ObjADORS
Const adPersistXML = 1

Set ObjADORS = Server.CreateObject("ADODB.Recordset")

'FileNumber, ClientFileNo, StatusDate, StatusTime, StatusComment
ObjADORS.Open "SELECT FormType, Description FROM FormTypes",
"DSN=kasecure1;uid=sa;pwd=pcbs"

ObjADORS.Save "c:\inetpub\wwwroot\manager\Test.xml", adPersistXML

ObjADORS.Close
Set ObjADORS = Nothing



Bob Barrows [MVP] 08-19-2004 03:29 PM

Re: Simple XML Example
 
James Baker wrote:
> I have a very simple query that gets a few records from a database.
> I need to take this, turn it into XML and post it to a client's
> website via VBScript. I was able to find an example of exporting the
> data to an XML file, but I'm lost on the syntax for actually posting
> the data to a third party page.


I'm not sure I quite undersatnd what you mean by this, but, does either of
these two examples help?
http://www.davidpenton.com/testsite/tips/

Bob Barrows

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.



James Baker 08-19-2004 03:34 PM

Re: Simple XML Example
 
I'll take a look, thanks for the links. To clarify, all I'm trying to do is
generate XML from a recordset and "send" it from an ASP page to a client's
website, where they can interpret it however they want. Does that make
sense?


"Bob Barrows [MVP]" <reb01501@NOyahoo.SPAMcom> wrote in message
news:erJ4SFghEHA.3664@TK2MSFTNGP12.phx.gbl...
> James Baker wrote:
> > I have a very simple query that gets a few records from a database.
> > I need to take this, turn it into XML and post it to a client's
> > website via VBScript. I was able to find an example of exporting the
> > data to an XML file, but I'm lost on the syntax for actually posting
> > the data to a third party page.

>
> I'm not sure I quite undersatnd what you mean by this, but, does either of
> these two examples help?
> http://www.davidpenton.com/testsite/tips/
>
> Bob Barrows
>
> --
> Microsoft MVP -- ASP/ASP.NET
> Please reply to the newsgroup. The email account listed in my From
> header is my spam trap, so I don't check it very often. You will get a
> quicker response by posting to the newsgroup.
>
>





All times are GMT. The time now is 09:22 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.