I have this xml:
<root>
<sub>maintext1
<subsub>subtext1</subsub>
<subsub>subtext2</subsub>
</sub>
</root>
I initially tried < sub>.Value, but this returned everything inside the sub, then < sub>.ToString which does the same thing. I searched for a solution but everywhere was used the xmlElement.InnerText but I need it for xElement which isn't available. How can I use the inner text property for the xElement?