Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Software > ADO Data > XML to ADO Reco...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 13 Topic 4220 of 4320
Post > Topic >>

XML to ADO Recordset and Back again

by "Barry Seymour" <bseymour@[EMAIL PROTECTED] > Apr 28, 2008 at 02:16 PM

I have a VB6 program that uses a global XML do***ent as it's data store. I 
want to convert that XML do***ent to an ADO recordset using ADO 2.7, sort 
and filter it, then convert that recordset *back* to an XML do***ent.

My problem occurs when I first open the XML do***ent; the resulting ADO 
recordset only has one record. I want to get them all.

Here's the code (Error handling omitted for clarity):
------------------------------------------------------------------------------------------------------------------------
Public Function ADORSFromXML(xmlDoc As MSXML2.DOMDo***ent40) As 
ADODB.Recordset

    With xmlDoc
        .setProperty "SelectionLanguage", "XPath"
        .setProperty "SelectionNamespaces", 
"xmlns:rs='urn:schemas-microsoft-com:rowset' xmlns:z='#RowsetSchema' 
xmlns:ms='urn:schemas-microsoft-com:xslt'"
    End With

    Set adoRS = New ADODB.Recordset
    adoRS.Open xmlDoc
    Set ADORSFromXML = adoRS  'return the recordset
    Set adoRS = Nothing
End Function
------------------------------------------------------------------------------------------------------------------------

Does anyone know why I'm only getting one record in my ADO recordset? I've

searched the Tubes high and low and can't find a clue.

Thanks in advance..

Barry
bseymour@[EMAIL PROTECTED]

 




 13 Posts in Topic:
XML to ADO Recordset and Back again
"Barry Seymour"  2008-04-28 14:16:48 
Re: XML to ADO Recordset and Back again
"Bob Barrows [MVP]&q  2008-04-28 17:37:23 
Re: XML to ADO Recordset and Back again
"Barry Seymour"  2008-04-28 15:02:46 
Re: XML to ADO Recordset and Back again
"Bob Barrows [MVP]&q  2008-04-28 18:49:44 
Re: XML to ADO Recordset and Back again
"Barry Seymour"  2008-04-28 16:02:15 
Re: XML to ADO Recordset and Back again
"Bob Barrows [MVP]&q  2008-04-28 19:13:25 
Re: XML to ADO Recordset and Back again
"Bob Barrows [MVP]&q  2008-04-29 08:50:58 
Re: XML to ADO Recordset and Back again
"Bob Barrows [MVP]&q  2008-04-29 08:55:52 
Re: XML to ADO Recordset and Back again
"Barry Seymour"  2008-04-29 09:13:42 
Re: XML to ADO Recordset and Back again
"Barry Seymour"  2008-04-29 09:19:22 
Re: XML to ADO Recordset and Back again
"Bob Barrows [MVP]&q  2008-04-29 12:48:40 
Re: XML to ADO Recordset and Back again
"Barry Seymour"  2008-04-29 10:05:35 
Re: XML to ADO Recordset and Back again
"Ralph" <nt_  2008-04-29 12:06:50 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Nov 22 14:08:38 CST 2008.