how to get xmlnode value based on attribute value in C#.
<Products>
<Error>0</Error>
<Product link="OWN">
<ProductCode>CA</ProductCode>
<ProductType>Account</ProductType>
<ProductSubtype>Current Account</ProductSubtype>
<ProductDescriptionEng>Current Account</ProductDescriptionEng>
<ProductNumber>1234567</ProductNumber>
<ProductCurrency></ProductCurrency>
<ProductCurrencyCode>01</ProductCurrencyCode>
<ProductBalance>899293.003</ProductBalance>
<LoanRef></LoanRef>
<OldLoanRef></OldLoanRef>
<ProductStandardID>00010001</ProductStandardID>
<OldLoanRef></OldLoanRef>
<ProductStatusCode>00</ProductStatusCode>
<ProductStatus>OPEN</ProductStatus>
<ProductCategory>Deposit Account</ProductCategory>
</Product>
</Product>
in the above example i would like to get value of Product Link "OWN" based on passing attribute value (1234567) 1234567.
I have tried following code but it doesn't return value "OWN" from 'Product link" node.
string _accountsXml = GetProducts();
_xmlDoc.LoadXml(_accountsXml);
_productLinkType = _xmlDoc.SelectSingleNode(string.Format("//Products[../ProductNumber = '{0}']", prodNumber));