开发者

Search databinded listboxitem from XmlNode

开发者 https://www.devze.com 2023-01-22 14:23 出处:网络
I\'m working on a c# wpf app in which I databind a listbox control to an xml datasource. Now I know that I can find the 开发者_运维技巧XmlNode that is linked to a listboxitem using datacontext. But no

I'm working on a c# wpf app in which I databind a listbox control to an xml datasource. Now I know that I can find the 开发者_运维技巧XmlNode that is linked to a listboxitem using datacontext. But now I want to go the other way around: Find the associated listboxitem when I have an xmlnode..

Any advice?


What about :

for each listboxitem, you retrieve the XmlNode, then, you use .Equals() on the node you have...

0

精彩评论

暂无评论...
验证码 换一张
取 消