Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can't convert this XML to cursor
Message
 
To
17/10/2005 11:21:31
Mike Sue-Ping
Cambridge, Ontario, Canada
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
Miscellaneous
Thread ID:
01059325
Message ID:
01059611
Views:
14
Hi Mike,

If method Load() or LoadXML() return .F., then XML file or XML string is not formal valid and you can not process the XML data.

MartinJ

>Hi Terry,
>
>I'm lost with your example. I am a dumb newbie when it comes to this stuff.
>
>Do you not have to load the XML file/string to the oXML object? I tried the oXML.LoadXML() and it returns .F. I've tried oXML.Load("c:\test.xml") and it returns .F. too.
>
>Where did oXMLChild come from?
>
>What does setProperty to XPath do and how do I know what valid values are for the first parameter?
>
>Mike
>
>
>>Even with a schema and an "xsi:schemaLocation" tag and the XSDs, you may not be able to use the adapter.
>>
>>Fortunately, with VFP, the command window and autocomplete you can work you way through the XML to figure out what needs to be done. Be sure to:
>>oXML=CREATEOBJECT("MSXML.DOMDocument") && Generic
>>oXML.async=.f.
>>oXML.setProperty("SelectionLanguage","XPath")

>>
>>and then look at some of the xml GET functions to validate the data and [then] retrieve it. Some examples:
>>if oXMLChild-getAttribute("myXMLTagName")==[C] && Is this tag there?
>>selectSingleNode("*[local-name()='myXMLTagName']") && Get one node

>>
>>You have the command window - and when learnig how to parse an XML - it comes in real handy!
"Navision is evil that needs to be erazed... to the ground"

Jabber: gorila@dione.zcu.cz
Jabber? Jabbim
Previous
Reply
Map
View

Click here to load this message in the networking platform