thanks peter, that using a literal delete... 
 
waht if you do delete via reference...  
 
e.g. node:XMLNode = xml.tagName["@id=3"];
 
if you delete node you've you tried to delete the new reference... how
do you delete the tag with an id attribute of 3?
 
Grant
 
 
 <http://www.bluetube.com/bti/images/small.jpg> 
...................................................
> b l u e t u b e i n t e r a c t i v e
.: The connection between creative and engineering
.: grant davies
.: 404.428.6839 (c)
.: 708-983-1577 (F)
> [EMAIL PROTECTED]
> http://www.bluetube.com/bti <http://www.bluetube.com/bti> 

 

 

________________________________

From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of Peter Farland
Sent: Wednesday, May 16, 2007 3:18 PM
To: [email protected]
Subject: RE: [flexcoders] finding and removing nodes from xml



http://livedocs.adobe.com/flex/2/langref/operators.html#delete_(XML
<http://livedocs.adobe.com/flex/2/langref/operators.html#delete_(XML> )

________________________________

From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of Grant Davies
Sent: Wednesday, May 16, 2007 3:05 PM
To: [email protected]
Subject: [flexcoders] finding and removing nodes from xml



I'm trying to find the most correct and efficient syntax to find nodes
with a particular attribute value and remove them from an xml document..


suppose my xml is :

<code>
<response>
<status-code>0</status-code>
<status-message><![CDATA[ The call was successful ]]></status-message>
<recipients>
<recipient id="5" firstName="John"
lastName="Smith">[EMAIL PROTECTED] <mailto:john%40blah.com> </recipient>
<recipient id="6" firstName="firstName"
lastName="lastName">[EMAIL PROTECTED] <mailto:chuck%40blah.com>
</recipient>
<recipient id="23" firstName="grant"
lastName="davies">[EMAIL PROTECTED] <mailto:grant%40blue.com> </recipient>
<recipient id="24" firstName="fool"
lastName="me">[EMAIL PROTECTED] <mailto:grant%40fool.com> </recipient>
<recipient id="25" firstName="frick"
lastName="frack">[EMAIL PROTECTED] <mailto:frick%40fool.com> </recipient>
<recipient id="26" firstName="grant"
lastName="davees">[EMAIL PROTECTED] <mailto:firday%40nowhere.com>
</recipient>
</recipients>
</response>
</code>

And I want to find recipients with an id of 6 and 23 and remove them
from the xml... What is the syntax for this?

I can find those nodes into an XMLList fine... Its removing them I'm
having fun with..

Cheers,
Grant




 

Reply via email to