I need to get value of child node from XDocument using linq
<root>
<Cust>
<ACTNumber>1234</ACTNumber>
<Address>
<Street></Street>
<City>123 Main street</City>
<State>AL</State>
</Address>
</Cust>
</root>
I tried this: xDocTest.Root.Elements("Cust").Elements("ACTNumber")
If I try Address instead of ACTNumber then it works. But its not giving the child node value.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…