Reputation: 931
I want to write a link query for my xml. Actually i dont know it. i have write some code here.
Dim query = _
From p In MyPermissionXml.Elements("menuNode").Descendants("menuNode") _
Where p.Attributes("title").ToString = "Company"
from where clause , i think it's wrong. how to represent an attribute here?
Upvotes: 0
Views: 900
Reputation: 10190
I think if you change Attributes to Attribute and ToString to Value and you should be there
Dim query = _
From p In MyPermissionXml.Elements("menuNode").Descendants("menuNode") _
Where p.Attribute("title").Value = "Company"
Upvotes: 1