I have a guide.xml file and that file contains multiple words / line I want to remove from the file.
Is there a batch file that can do that for me?
I want to run that batch as a scheduled task every day.
In this https://dl.dropboxusercontent.com/u/901529/Media%20Browser/Overige%20fora/guide.xml file are thes two words / line that I like to be removed from it.
1. (?)
2. dit is temp_8
Hope someone can help me out here.
Thanks and merry christmas
Delete certain text from xml file with a batch file
Moderator: DosItHelp
Re: Delete certain text from xml file with a batch file
Do you want to remove the entire lines that contain those terms?
Re: Delete certain text from xml file with a batch file
Just those terms. not the whole line.
Line like it is now
<title lang="nl">The big bang theory (?)</title>
<desc lang="nl">dit is temp_8 (Spike/tvgids.nl)</desc>
Like I would see it.
<title lang="nl">The big bang theory</title>
<desc lang="nl"> (Spike/tvgids.nl)</desc>
Line like it is now
<title lang="nl">The big bang theory (?)</title>
<desc lang="nl">dit is temp_8 (Spike/tvgids.nl)</desc>
Like I would see it.
<title lang="nl">The big bang theory</title>
<desc lang="nl"> (Spike/tvgids.nl)</desc>
Re: Delete certain text from xml file with a batch file
Code: Select all
@echo off
call jrepl "(?)" "" /L /I /F "guide.xml" /o -
call jrepl "dit is temp_8" "" /L /I /F "guide.xml" /o -
This above uses a native Windows batch script called Jrepl.bat (by dbenham)
jrepl.bat can be downloaded from: https://www.dropbox.com/s/4otci4d4s8x5ni4/Jrepl.bat
and it can also be found here: viewtopic.php?f=3&t=6044
Place it in the same folder as the batch file, or in a folder that is on the system path.
Re: Delete certain text from xml file with a batch file
foxidrive wrote:Code: Select all
@echo off
call jrepl "(?)" "" /L /I /F "guide.xml" /o -
call jrepl "dit is temp_8" "" /L /I /F "guide.xml" /o -
This above uses a native Windows batch script called Jrepl.bat (by dbenham)
jrepl.bat can be downloaded from: https://www.dropbox.com/s/4otci4d4s8x5ni4/Jrepl.bat
and it can also be found here: viewtopic.php?f=3&t=6044
Place it in the same folder as the batch file, or in a folder that is on the system path.
Thanks, this works.