hi guys.. i having this error while i try to search my xml file.
code behind
Dim xmldoc As XDocument = XDocument.Load(Server.MapPath("~/News.xml"))
Dim query = From record In xmldoc.Descendants("Details") Where record.Element("id").Value = 1112 Select record
If query.Count > 0 Then
Me.gvNews.DataSource = query.ToList
Me.gvNews.DataBind()
Else
Me.gvNews.DataBind()
End If
xml file
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<Setting>
<Details>
<id>1112</id>
<seo>test-2-bye-bye-malaysia</seo>
<type>text-and-images</type>
<posted-date>2015-03-31</posted-date>
<priority>10</priority>
<name>admin</name>
</Details>
</Setting>
gridview
Go to the complete details ...