Search found 127 matches

by mirrormirror
25 Jul 2016 02:10
Forum: DOS Batch Forum
Topic: need help parsing output
Replies: 25
Views: 4368

Re: need help parsing output

Thank you for the input on :strlen So after everything, I was poking around with the code you sent and changed it a bit. I would love to have an extra pair of eyes check it out to see if there are any issues with it. It works, but I have a few questions. Note: I decided to try the strlen.exe provide...
by mirrormirror
23 Jul 2016 18:25
Forum: DOS Batch Forum
Topic: Find and Replace in XML
Replies: 24
Views: 4140

Re: Find and Replace in XML

Not to distract from the code discussion here but I've read this tool can assist in command-line XML work:

https://sourceforge.net/projects/xmlstar/files/

Some usage info. here:

http://xmlstar.sourceforge.net/docs.php
by mirrormirror
23 Jul 2016 18:20
Forum: DOS Batch Forum
Topic: need help parsing output
Replies: 25
Views: 4368

Re: need help parsing output

Sorry - one more question concerning your code... Are you sure that the proper number of SETLOCAL / ENDLocal commands will be performed? Even if a large number of folders are processed in this loop? I just don't normally see the "SETLOCAL" performed in one loop and the "ENDLOCAL"...
by mirrormirror
23 Jul 2016 18:12
Forum: DOS Batch Forum
Topic: need help parsing output
Replies: 25
Views: 4368

Re: need help parsing output

aGerman - thank you for your help. I tested your latest code with an even more complex foldername and everything works fine. Also, if you have any input on the :strlen question I asked in the other post feel free to state it: http://www.dostips.com/forum/viewtopic.php?f=3&t=6044&p=48009#p48009
by mirrormirror
23 Jul 2016 18:09
Forum: DOS Batch Forum
Topic: JREPL.BAT v8.4 - regex text processor with support for text highlighting and alternate character sets
Replies: 440
Views: 205152

Re: JREPL.BAT - regex text processor - successor to REPL.BAT

Ok, thanks again - I appreciate your attention to detail and in writing up nice code (i.e. adding extra error handling & stripping out endlines, etc.). For me, these posts are not just about finding immediate solutions, but also learning. I think I have my solution. One more question... Concerni...
by mirrormirror
23 Jul 2016 17:46
Forum: DOS Batch Forum
Topic: need help parsing output
Replies: 25
Views: 4368

Re: need help parsing output

Ok. I am working up a short test script to see how this works...
by mirrormirror
23 Jul 2016 17:25
Forum: DOS Batch Forum
Topic: JREPL.BAT v8.4 - regex text processor with support for text highlighting and alternate character sets
Replies: 440
Views: 205152

Re: JREPL.BAT - regex text processor - successor to REPL.BAT

In addition to my response above I discovered another issue with the way the FOR loops strip out percents - it affects the test cases also - detailed more here:

http://www.dostips.com/forum/viewtopic.php?f=3&t=7305&p=48003#p48003
by mirrormirror
23 Jul 2016 17:21
Forum: DOS Batch Forum
Topic: need help parsing output
Replies: 25
Views: 4368

Re: need help parsing output

Thanks for continuing to look at this. I discovered a provlem with the test script. It is stripping out the "%" from both the folder creation as well as the search - for example: SET "directory1=1% 2% 3% 4^% 5% ) == =. a! b! c! d^! e! ^ ^ 'n1 = n +2 -( )))" IF NOT EXIST "%di...
by mirrormirror
23 Jul 2016 16:39
Forum: DOS Batch Forum
Topic: JREPL.BAT v8.4 - regex text processor with support for text highlighting and alternate character sets
Replies: 440
Views: 205152

Re: JREPL.BAT - regex text processor - successor to REPL.BAT

But you would have to show me a specific problem that you are having. I am sure there is a simple solution. If you run this code you can see the issue: @echo off &setlocal disableDelayedExpansion SET "directory=1% . a! b! c! ^ 'name1 = name +2" IF NOT EXIST "%directory%" MD ...
by mirrormirror
23 Jul 2016 15:58
Forum: DOS Batch Forum
Topic: need help parsing output
Replies: 25
Views: 4368

Re: need help parsing output

ok - thank you :)
by mirrormirror
23 Jul 2016 15:53
Forum: DOS Batch Forum
Topic: JREPL.BAT v8.4 - regex text processor with support for text highlighting and alternate character sets
Replies: 440
Views: 205152

Re: JREPL.BAT - regex text processor - successor to REPL.BAT

Thanks Dave, your solution works even with a crazy folder named "1% . a! b! c! ^ 'name1 = name +2". I like the following and will remember it for next time: I avoid having to add one to the string length by appending an extra character to the variable definition. I do have a few questions:...
by mirrormirror
23 Jul 2016 14:39
Forum: DOS Batch Forum
Topic: need help parsing output
Replies: 25
Views: 4368

Re: need help parsing output

Hello and thank you for the solution. It works on the foldername in my original post but fails with some special characters. If you run this script (it will create one new folder) you can see the failure: @echo off &setlocal DisableDelayedExpansion REM set "directory=c:\Program Files\Common...
by mirrormirror
23 Jul 2016 05:09
Forum: DOS Batch Forum
Topic: need help parsing output
Replies: 25
Views: 4368

need help parsing output

Hello all. I posted this same issue here: http://www.dostips.com/forum/viewtopic.php?f=3&t=6044&p=47986#p47986 I'm asking in the wider forum in case someone might have a solution ising findstr or something. I want to parse the output from this: C:\>icacls "c:\Program Files\Common Files&...
by mirrormirror
23 Jul 2016 04:52
Forum: DOS Batch Forum
Topic: JREPL.BAT v8.4 - regex text processor with support for text highlighting and alternate character sets
Replies: 440
Views: 205152

Re: JREPL.BAT - regex text processor - successor to REPL.BAT

Ok, I'm back with another problem This one is not crucual as I have a work-a-round but it is far from ideal. This is more of a jscript regex question. I want to parse the output from this: C:\>icacls "c:\Program Files\Common Files" c:\Program Files\Common Files NT SERVICE\TrustedInstaller:...
by mirrormirror
20 Jul 2016 20:02
Forum: DOS Batch Forum
Topic: JREPL.BAT v8.4 - regex text processor with support for text highlighting and alternate character sets
Replies: 440
Views: 205152

Re: JREPL.BAT - regex text processor - successor to REPL.BAT

But why do you need us to tell you that. All you need to do is prepare a file with traditionally "problem" characters, and see how the various solutions handle it. I suppose I am just looking to experienced users to advise me of any known limitations/issues I may encounter. DOS batch char...