xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns:kml="http://www.opengis.net/kml/2.2"
xmlns:atom="http://www.w3.org/2005/Atom">
pushpin_hl
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Rahul BhattPosted Jul 20, 2012, 3:26 AM
private void ReadXMLfile()
{
XmlDataDocument xmldoc = new XmlDataDocument();
string filepath = Server.MapPath("KML.xml");
XElement elmRoot = XElement.Load(filepath);
string longitude;
string latitude;
var v = (from page in elmRoot.Elements().Elements().Elements().Nodes()
select page);
if (v != null)
{
foreach (var item in v)
{
if (((XElement)item).Name.LocalName == "longitude")
{
longitude = ((XElement)item).Value;
}
if (((XElement)item).Name.LocalName == "latitude")
{
latitude = ((XElement)item).Value;
}
}
}
}