I have the following XML
<?xml version="1.0"?> <FileHeader xmlns="urn:schemas-ncr-com:ECPIX:CXF:FileStructure:020001" VersionNumber="020001" TestFileIndicator="P" CreationDate="13012009" CreationTime="172852" FileID="0000000001" > <Item ItemSeqNo="09011340010009" PayorBankRoutNo="00704524" Amount="398000" AccountNo="000003850010205" SerialNo="000512" TransCode="03" PresentingBankRoutNo="00400019" PresentmentDate="13012009" CycleNo="01" NumOfImageViews="2" ClearingType="01" DocType="D" CurrencyInd="LYD" IQAIgnoreInd="0" CashValueInd="1" TruncatingRTNo="00405117" SpecialHandling="00" RepresentmentCnt="0" MICRRepairFlags="000000" > <AddendA BOFDRoutNo="00400019" BOFDBusDate="13012009" DepositorAcct="0000534983" /> <ImageViewDetail ...
And I need to reach the "ImageViewDetail" element using the Select (xpath_expression) method of the XmlDocument.NET class.
The following code does not work
xmlDocument.Select("//Item/AddendA/ImageViewDetail");
if i don't delete
xmlns="urn:schemas-ncr-com:ECPIX:CXF:FileStructure:020001"
from the fileheader tag
What is the correct way to work with namespace here?
Thanks,
source share