Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: XML file not saving

From: David <daman@------.--->
To: NULL
Date: 11/1/2004 7:23:00 AM
I solved the file saving as I had a poorly named path.  I forgot the "/"
between path and file name.

However, the XML file that I get back is a little strange (see it below)
and I don't know how to process the responseCode child?  Below the XML
is my code for handling.

<?xml version="1.0"?>
<checkResults responseID="4652500648">
	<responseCode code="00" severity="0" description="successful
transmission"/>
	<resultSet>
		<item postingDate="2004-09-10" sequenceNumber="1" amount="83100"
checkNumber="000000215836"/>
		<item postingDate="2004-09-10" sequenceNumber="2" amount="450000"
checkNumber="000000216219"/>
		<item postingDate="2004-09-10" sequenceNumber="3" amount="1100"
checkNumber="000000215859"/>
	</resultSet>
</checkResults>

		Set xmlDoc = Server.CreateObject("Microsoft.xmldom")
		
		xmlDoc.async = False
		xmlDoc.load(strSaveFile)
		Set xmlRoot = xmlDoc.documentElement

		For Each xmlPNode In xmlRoot.childNodes

			strnode = xmlPNode.nodeName

		    If xmlPNode.childNodes.length > 0 Then

		        intRec = 0
		        'Loop through child nodes 
				For intI = 0 To xmlPNode.childNodes.length - 1
					Set xmlPCNode = xmlPNode.childNodes(intI)
					For Each xmlAtt in xmlPCNode.attributes
						Select Case xmlAtt.nodeName
							Case "amount"
								strckamt = xmlAtt.text
							Case "accountNumber"
								stracctno = DropZeros(xmlAtt.text)
								If IsEmpty(stracctno) Then
									'all zeros
									stracctno = "none"
								End If
							Case "checkNumber"
								strckno = DropZeros(xmlAtt.text)
								If IsEmpty(strckno) Then
									'all zeros
									strckno = "none"
								End If
							Case "postingDate"
								strposted = xmlAtt.text
							Case "sequenceNumber"
								strseqno = xmlAtt.text
							Case Else	'rt num
								strrtnum = xmlAtt.text
						End Select
					Next
					strRetrieveList = strRetrieveList & strseqno & "~" & strckamt & "~"
& stracctno & "~" & _
									strckno & "~" & strposted & "~" & strseqno & "~" & _
									"~" & rtnumber & "~"
					intRec = intRec + 1
					
		        Next
		        
		    End If
		    
		Next




*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent