【发布时间】:2011-02-15 16:06:12
【问题描述】:
Xml格式如下
<ExtraFields>
<Field id="Attribute 1" description="Attribute1">
<Value>Value of Attribute 1</Value>
<Field id="Attribute 2" description="Attribute2">
<Value>Value of Attribute 2</Value>
<Field id="Attribute 3" description="Attribute3">
<Value>Value of Attribute 3</Value>
</ExtraFields>
我正在编写一个应该返回以下值的 LINQ 语句
Value of Attribute 1
Value of Attribute 2
Value of Attribute 3
当父节点具有字段 id="Attribute X" description="AttributeX" 的属性时,它返回每个属性的值
【问题讨论】:
-
你能发布一些示例 xml 吗?还问一个问题?
-
嗨,Morpheus,我认为 XML 示例会有所帮助,并且可以稍微澄清一下您想要什么。你的问题有点不清楚(至少对我来说)。
-
抱歉不清楚。到目前为止,在过去的一年里,我从来没有在这里发布任何东西。这是我第一次。下次我会坚持正确的标准!!感谢您的回复!