使用 Linq To Xml 怎么样?
var xDoc = XDocument.Parse(xml); //OR XDocument.Load(filename)
string status = xDoc.Descendants("Status").First().Value;
编辑
我用来测试的xml
string xml = @"<?xml version=""1.0"" encoding=""utf-8""?>
<soap:Envelope xmlns:soap=""http://schemas.xmlsoap.org/soap/envelope/"" xmlns:xsi=""http://www.w3.org/2001/XMLSchema-instance"" xmlns:xsd=""http://www.w3.org/2001/XMLSchema"">
<soap:Body>
<ProcessRequestResponse>
<ProcessRequestResult>
<ConsumerAddEntryResponse>
<Status>Failed</Status>
</ConsumerAddEntryResponse>
</ProcessRequestResult>
</ProcessRequestResponse>
</soap:Body>
</soap:Envelope>";
编辑 2
string xml = @"<?xml version=""1.0"" encoding=""utf-8""?>
<soap:Envelope xmlns:soap=""http://schemas.xmlsoap.org/soap/envelope/"" xmlns:xsi=""http://www.w3.org/2001/XMLSchema-instance"" xmlns:xsd=""http://www.w3.org/2001/XMLSchema"">
<soap:Body>
<ProcessRequestResponse xmlns=""http://submission.api.domain/"">
<ProcessRequestResult>
<ConsumerAddEntryResponse>
<Status>Failed</Status>
</ConsumerAddEntryResponse>
</ProcessRequestResult>
</ProcessRequestResponse>
</soap:Body>
</soap:Envelope>";
var xDoc = XDocument.Parse(xml);
XNamespace ns = "http://submission.api.domain/";
string status = xDoc.Descendants(ns + "Status").First().Value;