Question Read XML through Linq

evanir

New member
Joined
Mar 23, 2014
Messages
1
Programming Experience
Beginner
Hi All

I am new to c# and linq. Could you please help me to parse the below xml through linq.

<?xml version="1.0" encoding="UTF-8"?>
<Dictionary>

<GrType Name="Lion">
<Item>
<ID> 1 </ID>
<Color1> "T1" </Color1>
<Color2> "T2" </Color2>
<Color3> "T3" </Color3>
<Color4> "T4" </Color4>
<Image>"C:\1.bmp" </Image>
</Item>

<Item>
<ID> 2 </ID>
<Color1> X1 </Color1>
<Color2> X2 </Color2>
<Color3> X3 </Color3>
<Color4> X4 </Color4>
<Image>"C:z2.bmp"</Image>
</Item>
</GrType>


<GrType Name="Tiger">
<Item>
<ID> 3 </ID>
<Color1> S1 </Color1>
<Color2> S2</Color2>
<Color3> S3</Color3>
<Color4> S4</Color4>
<Image>"C:\T1.bmp" </Image>
</Item>
</GrType>

</Dictionary>

Thank you,
ERKanth
 
Back
Top Bottom