Sorry I guess it isn't. Just checked one of my persisted rs' and your sample below is missing a whole schema section where details on the fields is described: (this shows at the top after the xmlns declarations ending in '#RowsetSchema')
<s:Schema id='RowsetSchema'>
</s:Schema>
Other than that it's got the same namespace declarations at the top. Actually without it your XML does not make much sense in that it declares '#RowsetSchema' but does not define it. Do you know if this part of the schema was removed?
>I don't create a connection. I did exactly like your example shows and the error message appears. I guess it is not an ADO Recordset then?
>
>Mike
>
>>You don't need a connection for this one. Just do this:
>>
>>r = CreateObject("Adodb.Recordset")
>>r.Open("myrsdata.xml")
>>
>>Should work if it is an ADO rs. (to the best of my guessing abilities, it is)
>>
>>>Hi Crescencio,
>>>
>>>I don't know if this is an XML-persisted ADO recordset, however, when I tried your suggestion to load the XML file into an ADO recorset, I get the following error:
>>>
>>>
>>>Microsoft Visual FoxPro 9.0
>>>OK
>>>Help
>>>OLE IDispatch exception code 0 from ADODB.Recordset: The connection cannot be used to perform this operation. It is either closed or invalid in this context...
>>>
>>>
>>>So does this mean that it is not an ADO recordset or did I miss something?
>>>
>>>Mike
>>>
>>>
>>>
>>>>Isn't this xdr for an XML-persisted ADO recordset?
>>>>
>>>>Try instantiating and ADO recordset object, and loading from file. From there you can convert to VFP cursor if need be, but you wouldn't have to. (unless you want to bind)
>>>>
>>>>ex: myRs.Open("myfile.xml")
>>>>
>>>>>I have an XML file with the following format:
>>>>>
>>>>>
>>>>><xml xmlns:s='uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882'
>>>>> xmlns:dt='uuid:C2F41010-65B3-11d1-A29F-00AA00C14882'
>>>>> xmlns:rs='urn:schemas-microsoft-com:rowset'
>>>>> xmlns:z='#RowsetSchema'>
>>>>><rs:data>
>>>>><z:row Field1='Field1' Field2='Field2' Field3='Field3' Field4='Field4' />
>>>>></rs:data>
>>>>></xml>
>>>>>
>>>>>
>>>>>Can VFP load this into a cursor showing one row and four fields? I've tried XMLTOCURSOR() and XMLADAPTER but neither can produce the results I need.
>>>>>
>>>>>TIA
>>>>>
>>>>>Mike