D
David A. Osborn
Currently I have an XML file that come from an external program that looks
something like this:
<?xml version="1.0" ?><XML_FRUITBOWL_DATA_FILE FILEVERSION="1"
APPVERSION="19">
<FRUITBOWL Name="bowl1" Size="6" >
<FRUIT Type="Apple" Quanity="1" Size="Big"
Brand="Red Del." >
</FRUIT>
<FRUIT Type="Orange" Quanity="2" Size="small"
Brand="none">
</FRUIT>
</FRUIT BOWL>
<FRUITBOWL Name="bowl2" Size="24" >
<FRUIT Type="Apple" Quanity="16" Size="small"
Brand="Other" >
</FRUIT>
<FRUIT Type="Grape" Quanity="2" Size="medium"
Brand="none">
</FRUIT>
</FRUIT BOWL>
</XML_FRUITBOWL_DATA_FILE>
At any time the external program could change and a new property could be
added. What is the best way for me to interact with this file? Can I read
it in as a generic object and access properties with the dot notation? Or
do I need to interact with the file with SQL statement with ADO .NET?
something like this:
<?xml version="1.0" ?><XML_FRUITBOWL_DATA_FILE FILEVERSION="1"
APPVERSION="19">
<FRUITBOWL Name="bowl1" Size="6" >
<FRUIT Type="Apple" Quanity="1" Size="Big"
Brand="Red Del." >
</FRUIT>
<FRUIT Type="Orange" Quanity="2" Size="small"
Brand="none">
</FRUIT>
</FRUIT BOWL>
<FRUITBOWL Name="bowl2" Size="24" >
<FRUIT Type="Apple" Quanity="16" Size="small"
Brand="Other" >
</FRUIT>
<FRUIT Type="Grape" Quanity="2" Size="medium"
Brand="none">
</FRUIT>
</FRUIT BOWL>
</XML_FRUITBOWL_DATA_FILE>
At any time the external program could change and a new property could be
added. What is the best way for me to interact with this file? Can I read
it in as a generic object and access properties with the dot notation? Or
do I need to interact with the file with SQL statement with ADO .NET?