Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using XMLAdapter or CA with XML as DataSourceType
Message
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows 2000 SP4
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01009080
Message ID:
01009087
Views:
21
This message has been marked as the solution to the initial question of the thread.
Hi Mark,

Try
oCA = CREATEOBJECT("CursorAdapter")
oCA.Alias = "TestXml"
oCA.DataSourceType = "XML"
oCA.CursorSchema = "oldsku V(10), newsku V(10)"
oCA.SelectCmd = "test.xml"        && The name of memo field
oCA.CursorFill(.t.)
...
SKIP IN test
oCA.CursorRefresh()
>Let's say I have an XML file that looks like:
<snip>>
>The VFP Help file is not very helpful in examples for either using the XMLAdapter or a CursorAdapter with the DataSourceType set to XML. What I need to do is be able to load this XML into a cursor for display purposes only. This XML data is in the memo field of a VFP table, so as I skip through the records, I would like to "reload" the adapter with the new data from the XML information. This will all be read only so updating will not be necessary. I do not particularly want to go the XMLTOCURSOR route if possible as I think a "CursorRefresh" would be more efficient. I would also like to specify the cursor schema to be V(10) for both of those fields. TIA!
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform