Which value do you want if there is no Notes
element, a null, an empty string?
I would select the Row
elements with SelectNodes
and then check whether a Notes
child exists and assign null (as done below) or the empty string if not:
foreach (XmlElement row in doc.SelectNodes("//Row"))
{
string prop = row.SelectSingleNode("Property").InnerText;
string notes = row.SelectSingleNode("Notes") != null ? row.SelectSingleNode("Notes").InnerText : null;
}