This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes XML and Related Technologies and the fly likes error while inserting a node into a dom using a java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "error while inserting a node into a dom using a java" Watch "error while inserting a node into a dom using a java" New topic
Author

error while inserting a node into a dom using a java

s ithu
Greenhorn

Joined: Apr 10, 2012
Posts: 11
hi guys,

i am trying to insert a node into a dom using a java method.

But i get this error
hierarchy request_err : An attempt was made to insert a node where it is not permitted

so i changed permission using chmod command but still it is not working ......



Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8



This was the line which threw the exception, right? Well, you can't make a node be its own child. Probably you meant for the node to be a child of something else.
s ithu
Greenhorn

Joined: Apr 10, 2012
Posts: 11
Thank you for your help
I changed code like this so it is working now.

 
It is sorta covered in the JavaRanch Style Guide.
 
subject: error while inserting a node into a dom using a java
 
Similar Threads
Problem in creating XML using DOM
problem in modification of the value in xml file
Xml result is not coming.
Help regarding how to check the element entered is equal or not in xml file
Java code to append data into a existing xml file