Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I have a ini file looking like this(autodist.ini)Copy1=\\jj4300\Update\*.lzh=>c:\TilButik\jj1234
Copy2=\\jj4300\Update\*.bat=>c:\TilButik
Copy3=\\jj4300\Update\*.200=>c:\TilButik
Copy4=\\jj4300\Update\*.100=>c:\TilButikIn that file I would like to replace some of the lines with lines found in an other file (replace.ini) looking like this.
Copy1=\\jj4300Update\Denmark\*.lzh=>c:\TilButik\jj1111
Copy2=\\jj4300\Update\Norway\*.bat=>c:\TilButik
Copy3=\\jj4300\Update\Denmark\*.200=>c:\TilButik
Copy4=\\jj4300\Update\Norway\*.100=>c:\TilButikThe only thing unique for bout files is the first 8 letters.
The hole thing should run in a Batch file. So if somebody now about a tool that can fix this please help me.
Best regards Kai74

hi there
following will resolve your issue.
it replace "&" with "&" in dirlist.xml and will write the results to dirlist1.xmlplease make sure that input file and output file should be different
hope it helps
/sajjad@echo off
:: Create the assembler program, by Herbert Kleebauer
echo Bj@jzh`0X-`/PPPPPPa(DE(DM(DO(Dh(Ls(Lu(LX(LeZRR]EEEUYRX2Dx=> %temp%.\sbs2.com
echo 0DxFP,0Xx.t0P,=XtGsB4o@$?PIyU!WvX0GwUY Wv;ovBX2Gv0ExGIuht6>> %temp%.\sbs2.com
echo ?@}IKuNWpe~Fpe?FNHlF?wGMECIQqo{Ox{T?kPv@jeoSeIlRFD@{AyEKj@>> %temp%.\sbs2.com
echo iqe~1NeAyR?mHAG~BGRgB{~H?o~TsdgCYqe?HR~upkpBG?~slJBCyA?@xA>> %temp%.\sbs2.com
echo LZp{xq`Cs?H[C_vHDyB?Hos@QslFA@wQ~~x}viH}`LYNBGyA?@xAB?sUq`>> %temp%.\sbs2.com
echo LRy@PwtCYQEuFK@A~BxPtDss@fFqjVmzD@qBEOEenU?`eHHeBCMs?FExep>> %temp%.\sbs2.com
echo LHsPBGyA?@xAunjzA}EKNs@CA?wQpQpKLBHv?s`WJ`LRCYyIWMJaejCksl>> %temp%.\sbs2.com
echo H[GyFGhHBwHZjjHeoFasuFUJeHeB?OsQH[xeHCPvqFj@oq@eNc?~}Nu??O>> %temp%.\sbs2.com
echo ~oEwoAjBKs?Zp`LBzHQzyEFrAWAG{EFrAqAGYwHTECIQ{coKIsaCsf{Oe~>> %temp%.\sbs2.com
echo CK}Ayre~CNFA{rAyEKFACrA{EKGAjbA}eKGSjNMtQFtc{OAyDGFj?{FDGQ>> %temp%.\sbs2.com
echo KAjNVk_OCAx@e?f{o?CosI}1EGizhljJ~H1ZeG}JBA~rACBMDGjjDG@g0>> %temp%.\sbs2.com:: Use the program
%temp%.\sbs2.com 0 "&" "&" < c:\dirlist.xml > c:\dirlist1.xml
:: Delete the program
del %temp%.\sbs2.com

HI sajjadr21
Hm. I'm not sure about what you mean!! Is it possibel to explain this a bit clearer..Best Regards Kai74

Hi Kai74
Hi
would something along these lines help, or
do the lines have to be in the same place as the replaced lines.Find lines thaton'thave "jj4300re\Update" and write to NewFile.ini
/v lines that don't contain the text
/i ignore case, might not be needed
\Update" >newfile.ini
rem find files in second file and append to file rem NewFile.ini--------------------
@echo off
type autodist.ini | find /v /i "jj4300
type replace.ini | find "jj4300\Update" >> newfile.ini
--------------------

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |