I am generating the xml given below for a vendor based upon their specs, using the xmladapter, vfp9 sp2.
I am using 'set relation code' and 'respect nesting' such that the xml is nested properly. However, in the sample I generated below,
the fields notes, publication_code, pagination_code,ad_sold_by, and billing_flag appear immediately after adbasepreprintinfo
It seems like in general that vfp wants the data fields that belongs with higher level data to appear above table data that is nested below it. However, the vendor wants the notes, publication_code, pagination_code,ad_sold_by, and billing_flag fields to appear after the ending tag for ordercustomers and before the preprintinsert tag
Is there a way to do this with the xmladapter? I guess I could do some postprocessing on the file or memory variable to force it into the right position, but at the moment it seems to me that this would be some tricky coding.
Will I have to 'hand code' this?
<?xml version = "1.0" encoding="Windows-1252" standalone="yes"?>
<AdBaseData>
<AdbasePriprintInfo>
<notes>note?</notes>
<publication_code>Y</publication_code>
<pagination_code>N</pagination_code>
<ad_sold_by>repx</ad_sold_by>
<billing_flag>N</billing_flag>
<OrderCustomers>
<OrderCustomer>
<isprimaryorderer>true</isprimaryorderer>
<isprimarypayor>true</isprimarypayor>
<Customer>
<name1>xxx<name1>
</Customer>
</OrderCustomer>
</OrderCustomers>
<PriPrintInsert>
<sides>1</sides>
<pagecount>2 STD</pagecount>
<weight>0.23400</weight>
<externalordernumber>1296543VERSION A</externalordernumber>
<priprinttype>Tab</priprinttype>
</PriPrintInsert>
</AdbasePriprintInfo>
</AdBaseData>