Populate dropdown using XML

  • Thread starter Thread starter brian
  • Start date Start date
B

brian

I have never done anything with XML and would like to
figure out how to populate a dropdown with XML in ASP.NET
using VB.

The dropdown will only contain years as a field and a
value. Such as 2004, 2003, 2002, 2001. I need help
constructing the document.

Then I need to populate the dropdown box with the XML
data.

I know there are other ways of doing this but I would
like get my feel wet with some XML.

IF anyone has any good links for begining XML please send
them my way.

Thanks
 
Something along the lines of

imports System.Xml ' Goes at the top of your code

Dim MyList as XmlNodeList
MyList = MyXmlDocument.SelectNodes("root/years")
if (MyList is not nothing) then
foreach MyYear as XmlNode in MyList
Response.Write(MyList.InnerText)
Response.Write(MyList.Value) ' memory is fuzzy and i dont
work in vb and i'm don't have intellisense for languages in my email client
Next
end if

the following code should be able to be adaptable
 
Back
Top