【发布时间】:2009-10-20 22:20:10
【问题描述】:
我想在 xml 文件中进行搜索。这是我的 linq 语句。
string _sSemptom = "try";
XElement xe = from c in xdSemptom.Elements().Elements().Elements()
.Elements().Attributes("Isim")
where c.Value.Length >= _sSemptom.Length &&
c.Value.Contains(_sSemptom)
select c.Parent
我可以通过这种方式找到 XElement,但如果 _sSemptom 是“Try”,我就找不到它。如何使用大小写变体进行搜索?
感谢您的帮助。
【问题讨论】:
标签: c# xml linq linq-to-xml