another method ...
Dim id
id = xmldoc.selectSingleNode("/xiam/deliverRequest/@id").nodeTypedValue
Jut a personal preference to have the attribute as part of the Xpath (I think this works without
setting the SelectionLanguage property for the xmldoc?).
Chris.
"Bob Barrows [MVP]" <re******@NOyahoo.SPAMcom> wrote in message
news:%2******************@TK2MSFTNGP10.phx.gbl...
Shawn wrote:
I have an XML file that contains nodes and I'm having no problem
extracting the information using ASP. However I can't seem to get the
ID number from the deliverrequest node from the example below.
Driving me crazy.. any help would be appreciated. Thanks
<!DOCTYPE xiamSMS SYSTEM "Message.dtd">
<xiam>
<deliverRequest id="10234690"> ''' Need to retrieve this number using
ASP
<to>test</to>
<from>number</from>
<content type="text">Test 2</content>
</deliverRequest>
</xiam>
Thanks.
dim id
id=xmldoc.selectSingleNode("/xiam/deliverRequest").getAttribute("id")
HTH,
Bob Barrows
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (
http://www.grisoft.com).
Version: 6.0.777 / Virus Database: 524 - Release Date: 14/10/2004