RE: changing Attribute of Node

2001-10-16 Thread Scott Moore
r 16, 2001 2:32 AM To: [EMAIL PROTECTED] Subject: Re: changing Attribute of Node Sorry I mean how to change attribute of any Node. Shashank wrote: > I posted a question few days ago, regarding how to changing Node > Attribute. > > This API is available for an Element, but a

Re: changing Attribute of Node

2001-10-16 Thread Shashank
Sorry I mean how to change attribute of any Node. Shashank wrote: > I posted a question few days ago, regarding how to changing Node > Attribute. > > This API is available for an Element, but a Node is not an Element. > > So then how to change the Attribute of any Element. > > Does anyone has s

changing Attribute of Node

2001-10-16 Thread Shashank
I posted a question few days ago, regarding how to changing Node Attribute. This API is available for an Element, but a Node is not an Element. So then how to change the Attribute of any Element. Does anyone has some simple example to change this. take carre Shashank --

Re: changing attribute of Node

2001-10-14 Thread Rahul Srivastava
Why do you need to cast an attribute node to Element?. If you want to change the value of an attribute you can do it as: Element element; NamedNodeMap attributes = element.getAttributes(); Node attribute = attributes.getNamedItem("name of attribute to change"); attribute.setNodeValue("new v

Re: changing attribute of Node

2001-10-12 Thread Shashank
TECTED]> > g.nu> cc: > Subject: changing attribute of > Node > 10/12/01 > 10:09 AM > Please > respond to > xerces-j

Re: changing attribute of Node

2001-10-12 Thread Shashank
Casting org.w3c.Node(s) to Element is giving ClassCastException If I try printing Class of this Node (which I try casting to type Element) it prints class Type is org.apache.xerces.dom.DeferredAttrNSImpl java.lang.ClassCastException: org.apache.xerces.dom.DeferredAttrNSImpl

Re: changing attribute of Node

2001-10-12 Thread TLSteinmetz
Subject: changing attribute of Node 10/12/01

Re: changing attribute of Node

2001-10-12 Thread Rahul Srivastava
The attributes of an element node are again org.w3c.Node(s). So, you can use the same set of APIs to modify the attribute as for elements. :-) Cheers, Rahul. > From: Shashank <[EMAIL PROTECTED]> > > Hi ! > > I am using xerces parser for parsing XML file and reading and changing > Node value.

changing attribute of Node

2001-10-12 Thread Shashank
Hi ! I am using xerces parser for parsing XML file and reading and changing Node value. but how to change the attribute of this Node. I didn't find correct API. I can read the value of Node's attribute, but then how to change this value. take care, Shashank -- ---