Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem with XML schema
Message
 
To
21/03/2004 20:49:43
General information
Forum:
ASP.NET
Category:
XML
Miscellaneous
Thread ID:
00888315
Message ID:
00888369
Views:
13
I'm sorry, I did not appreciate that you are building this from .NET - is there not a similar function to XMLAdapter in .NET (I haven't done anything in .NET)?

But on the VFP side, I am keeping a table with the correct structure for the XML being passed - so if I *receive* an XML message without the schema I do something like this:

ln_recs = XMLTOCURSOR(pc_XMLRecord, "CustVendCursor")
IF ln_recs > 0
COPY TO (lc_tmpdir + lc_cvtemp + ".dbf") && a temporary table
USE IN CustVendCursor

USE (CustVendXMLDefTable) ALIAS CustVendDef NOUPDATE SHARED
*-- a "standard" table I can use in case the schema was missing and therefore the data was not correctly formatted (e.g. if one character passed in a field capable of (say) 6 characters then the field is only one character wide)

COPY STRUCTURE TO (lc_tmpdir + lc_cvtable + ".dbf") && the table we will now use
USE IN CustVendDef

*-- Open the table that has the correct structure
USE (lc_tmpdir + lc_cvtable + ".dbf") ALIAS Clients EXCLUSIVE

*-- Append the records passed without the schema
APPEND FROM (lc_tmpdir + lc_cvtemp + ".dbf")
ENDIF


ERASE (lc_tmpdir + lc_cvtemp + ".dbf")
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform