Hi guys,
I am quite basic with C# but i was wondering would anyone be able to give me some example code to the following question. XML is really confusing me.
Basicly my problem is:
I have a string string.
I want to compare the string with data i have in an XML file. the reason for this is because i want to give the user the ability to update the xml whenever they want and add new data.
so basicly, the string I have is a section of data from a file. I want to compare the data and then see which one it matches in my xml.
they are a range of articals, such as sports, games and eventually i will be expanding the list to be even longer. once i have matched them up.... say the data in the string comes from a file called hamlar.txt. i want to then display hamlar.txt in a listbox to whatever it matches up to. so say the string from hamlar.txt matches football, and is in sports. it then adds the hamlar.txt file name to a listbox. when you click the name in the list box, it displays a label saying "football"...
this will be expanded massivly... i am just keeping it simple above so i have a stepping stone and something to work from...
the xml file i have:
="1.0"
<References>
<sports>
<Ref type = "football">11 man team</Ref>
<Ref type = "tennis">40 love</Ref>
<Ref type = "cricket">hit a 6</Ref>
</sports>
<games>
<Ref type = "monopoly">take £200</Ref>
<Ref type = "CS">counter terrorists</Ref>
<Ref type = "fallout">collect caps</Ref>
</games>
</References>
obviously the file i have will be far far far far larger than this will LOADS of stuff in it.
does that make sense?
many thanks in advance.
Hyps