Extracting text from XML file via batch file -
I have to remove some text from an XML file through a batch file, one of the parts I need to remove The string is between the tag ( ; Type Output.TT000000000@gmail.com Default Web For The password www.instagram.com (000000000@gmail.com) www.instagram.com Cheers, G & lt; string & gt; example1 & lt; / string & gt; ) and the second data tag (
& lt; data & gt; example2 & lt; / Data & gt; ). Any idea how? thank you in advanced!
@echo OFF for output.txt / f "delims =" job "% % I "Goto: EOF: Job Set Line =% 1 Set Line =% Row: / = %% i ('findstr / i / c:' & lt; string & gt;" xml_file.xml ') Call: % Set line =% line: & lt; = +% set line =% line: & gt; = +% set line =% line: * + string + =% set row =% row: + = & amp; rim % Echo.% OP with the input file -
D: \> Draft.bat D: \> gt; & gt; Output. Txt: eof
Comments
Post a Comment