I have xml file in which i want to edit or add or delete the contents..
Hi
I need your help, How to remove some contents and modify some contents from xml file...
<book>
<peson>
<name> AAA</name>
<age>12 </age>
</person>
<peson>
<name> DAA</name>
<age>21 </age>
</person>
<peson>
<name> CAA</name>
<age>32 </age>
</person>
<peson>
<name> CAA</name>
<age>21 </age>
</person>
This is my xml file, i want to remove whole <person> if the age is 21 ... and modify some name based on age..How to do in java ......... Please advise me...I will be thankful to you in this regards.
Here you can read about java + xml
http://java.sun.com/developer/codesamples/xml.html
do note that your xml does not look well formed to me, and will most likely raise errors.
Similar Messages
-
Hi,
I have an data file in which I want to write my new data. The problem is how to overwrite the old data in this file or to delete first the content of this file.
ThanksHi Heelclick,
Open the LastRun.VI attached in this thread. It uses "New File" to create a new file every time it saves a file. Notice, too, that overwrite=true - there will be no warning if file already exists.
Cheers
Message Edited by tbd on 01-12-2007 03:39 AM
"Inside every large program is a small program struggling to get out." (attributed to Tony Hoare) -
I have just bought a new mac book, and I want to start from scratch by syncing the content of my iPhone, but each time I try it wants to delete everything on the iPhone and replace by what's on the new iTunes library, i.e. nothing! can I do the reverse, i.e. importing all my iphone's stuff on the new computer?
You need to copy some files and your iTunes folder to the new computer. Do you have a backup of your old computer (or still have the old computer?) Was the old computer a Mac or PC?
MacWorld - Move an iTunes library from a Windows PC to a Mac
Back up your iTunes library by copying to an external hard drive
iTunes- How to move your music to a new computer -
Hi, I have a new cell phone, I wanted to give my iphone to my father, instead of deleting the content on the iphone I have deleted the entire iphone. It starts up no more. iTunes will not recognize the iphone. How do I get my old data back onto the phone?
Place the device in DFU mode (google it) and restore as new.
-
I have a band video that I want to edit. In iMove 09, I could clip to crop or add a transition or both without altering the audio. In iMovie 11, the audio lower or drops out when I clip for and use a transtion. Is there a setting to preven this?
Thanks for that info! Even in my time answering questions on iMovie Discussion Group, I never had a good understanding of when and how Optimize Movie came into play. I always would import as Optimized and Large Size and figured that was good enough. But knowing you got much, much more flexibility doing it the way you describe gives me a much better understanding of the different routes you can take into the Event Library.
-
purpose: to create photo galleries to insert or not items:
1) with phocagalery, it works
2) with the transfer via lightroom, I do not see the downloaded files but if I want to create a directory folder with the same name, he said he is already, I see nothing in the media in content management
Can you help meMahsa21,
We are glad that we were able to resolve the international calling plan issue for you. If you need assistance,please reach out to us.
thanks,
Tonya D. -
I have 91 file that are pdfs i need to make searchable what is the best way of doing this
help
i have 91 file that are pdfs i need to make searchable what is the best way of doing thisHi ismaelr61128862,
I would recommend you to try Advanced search option of Acrobat software, Go to Edit and then Advanced search.
Hope that helps. In case you have any further questions please provide sufficient amount of details so that i can assist you more accurately.
Regards,
Rahul -
We each have our own device, a laptop and an iPad. when sending imessages recipients cannot tell which of us sent it other than looking at the content. Is there any way to add an identifier to make it clear who is sending the message? I know we can say 'this is mom or this is dad" but when an email is sent it identifies the device that sent it so why not imessages too?
Stop using the same apple id on all your devices. Each person should have their own. You can still share apps via home sharing.
-
I recently added my entire music library to the "cloud" for an annual fee. Now I can't listen to anything unless I have an internet connection. I want my library back on my laptop, the whole thing (original laptop got erased). How do I do this?
Hello ggjsa,
Congratulations on your new laptop! I understand that you have copied your old iTunes Library to your new computer, but you are still not seeing the music. I recommend reviewing Part 5 in the section titled "External drive" in the following article:
iTunes: How to move your music to a new computer
http://support.apple.com/kb/ht4527
If you are still having trouble transferring the library using this method, you may want to try using the Home Sharing method in the article.
Thank you for using Apple Support Communities.
Best,
Sheila M. -
i have made a photo book and want to ship to address in USA the drop box for shipping address stays Canada how do i ship to a us address
Go to the iPhoto Advanced preference pane and change the Print Products Store location to the US.
Then order the book.
OT -
Ok to Delete the Contents of the Render Files Folder?
Hello Hello
I remember from using various PC Video Editing programs that each program established for itself a 'Render Folder', or sometimes called an 'Auxiliary Folder'.
This folder contained the contents of the previously rendered files as they related to a particular DVD burned project. Once rendered, the files were there to sort of help reduce the process time, (render time), required to burn another DVD disc.
In FCE HD, there is also a folder called 'Render Files', and also another folder called 'Audio Render Files'. Naturally the contents of these folders could easily amount to 2 gigs or more depending upon the project size.
Well - (aside from increasing Re-Rendering Time in regard to a new DVD burn), is it safe to delete the contents of the 'Render Folder' in an effort to free up hard drive space?
Thanx
MikeHi Mike,
You may have a couple of things mixed up.
In FCE the Render Files and Audio Render Files folders hold the render files produced by FCE. FCE uses those render files when you play the timeline, print to video or export a movie. You can delete them at any time because you can always re-render in FCE. However, you do need to be careful at the point when you export a movie from FCE (for example, to use in iDVD)
If you export to a QT Self-Contained movie, all the media for the movie you export (including rendered video & audio) is incorporated into the resulting QT movie file. Assuming a successful export, you no longer need the FCE render files.
However, if you export to a QT Reference movie, you need to keep the FCE render files available when you import your project into iDVD and build your DVD structure. When iDVD encodes & multiplexes to burn your DVD, it will use the QT Reference movie, which in turn uses the FCE render files (and your original media).
In iDVD, after you burn your DVD, you have the option of keeping the 'rendered assets'; these are iDVD render files and are inside your iDVD project file; they are not the FCE render files.
If you really want to save time burning subsequent DVDs, in iDVD you should Save As Disk Image (instead of Burn DVD), which gives you a completely finished, fully encoded & formatted DVD disk image. You can then use the Finder, Disk Utility or Toast to burn additional DVDs for only the burn time, you won't have to go through iDVD's menus & re-rendering just to burn an additional DVD. -
I opened a file to print and by accident highlighted and deleted the content. Then in a panic I closed the file and now when I open it is blank. Is there any way to get it back. I have looked and can not see anyway. I dont have anything in my backup?
I'm not sure about older versions, but in Pages 3.x (OS X 10.9.x) select File > Revert To > Browse All Versions. Hopefully there will be an earlier version that you can "revert to".
-
i've tried multiply times to update itunes 10.5 but it keeps saying that it can't find the file and i can't reinstall itunes because it will delete the 100 gigabites of info on it what can i do
I've had all kinds of trouble keeping my iTunes software current over the past year, but have found the easiest way to remedy the issue is to simply download the latest version of iTunes as though I am a first-time user and then just install it into the directory my current version of iTunes is using. Doing this has allowed me to update my software without losing any of my media/data. Hope this helps! Best of luck!!!
-
How to delete xml content without deleting the content of the object?
Hey, with the following code I am marking up a page item and deleting it's xml content:
text_value = text_area.xmlElements.add('text', current)
text_value.contents = '';
current is the current app.selection. The code works, with one downside: It also deletes the content of my text frame in my document. I only want to delete the xml content. Is this somehow possible?
Thanks in advance!!
Regards
FredDear Fred,
Please use the below Code, this will helps you to achieve your target.
//============================== Script Starts ============================================//
var doc = app.documents[0];
//========================================================================//
/* Use Glue Code */
//==================================================================//
__RemoveXMLElments(doc);
function __RemoveXMLElments(doc)
var elementXpath = "//text";
var myRuleSet = new Array (new __RemoveXMLElments_XPath(elementXpath));
with(doc){
var elements = xmlElements;
__processRuleSet(elements.item(0), myRuleSet);
function __RemoveXMLElments_XPath (Txts)
this.name = "RemoveTexts";
this.xpath = Txts;
this.apply = function(myElement, myRuleProcessor){
with(myElement){
try{
var myCnts = myElement.texts.everyItem();
myCnts.remove();
}catch(e)
//============================== Script End============================================//
Thanks & Regards
T.R.Harihara SudhaN -
I just installed iTunes on my computer, where I already have all my music. I went to Edit > Preferences > Advanced, and changed the iTunes Media Folder Location to where I have all my music, in the "Local Disk." But iTunes wont import all my music. Help?
Have you looked in the Music App on your iPhone? On the iPhone music is played by the Music App not iTunes.
Maybe you are looking for
-
Can i use two 2gb ddr3 on my lenovo g400 ??
and can i use ddr3 and ddr2 on my lenovo g400??
-
Canon 5D mark II raw file conversion size blowout
I am suffering from an issue where my CR2 files from a 5D decrease in size when converted to DNG from for example 14.4MB to 11.8MB while the 5D mark II files increase from 8.7MB to a much larger 23.6MB after conversion. Both conversions are being do
-
Macbinary file in home directory
Hello, I have noted lately that there is a mac binary file in my home directory, does anyone know what is this for? I did not notice this file a month and half ago. Everything else is ok with my mac but I am very curious about this file. I tried open
-
My Finder Icon in desktop invincible
My Finder Icon in my Desktop won't show up, but i can use it and the dot under it glows. I've Tried re-booting, Safe boot aswell But it won't work. I messed up trying to change the icon picture with the iOS 7 Finder Picture, ended up that the icon no
-
AVERAGE on crosstable with NULLs
Hi, I try to set average function on column in crosstable. Data contains NULLs. I got error during displaing report in HTML format (in Interactive format it's ok) - "oracle.xdo.XDOException: java.lang.reflect.InvocationTargetException". Oracle suppor