Search found 87 matches

by bars143
02 Nov 2013 11:46
Forum: DOS Batch Forum
Topic: help sorting list of filename by its string lenght
Replies: 24
Views: 10687

Re: help sorting list of filename by its string lenght

foxi, thanks again for an explanation. its an existence of temp.tmp which shared the same folder of batch code -- is the cause all the trouble for me. i did test afterward for other possible causes, and i found out that without this script : del temp.tmp 2>nul or converted as a comment: rem del temp...
by bars143
02 Nov 2013 08:05
Forum: DOS Batch Forum
Topic: help sorting list of filename by its string lenght
Replies: 24
Views: 10687

Re: help sorting list of filename by its string lenght

foxi, its really work to your original 3rd code ! finally, i find out the problem is this script: an addition of echo in " echo del temp.tmp 2>nul " or deleting this script: " del temp.tmp 2>nul " this should be added as rem (to remind me of importance): @echo off :: sort names b...
by bars143
02 Nov 2013 04:15
Forum: DOS Batch Forum
Topic: help sorting list of filename by its string lenght
Replies: 24
Views: 10687

Re: help sorting list of filename by its string lenght

foxi, a file.txt content i used is the same as of temp.tmp . and if it is no content - it give error. then, i didnt ask you first of what inside the file.txt in your 3rd method and i decide myself thats content of file.txt is an input. this is what i means that a red colored font is content is an in...
by bars143
01 Nov 2013 22:47
Forum: DOS Batch Forum
Topic: help sorting list of filename by its string lenght
Replies: 24
Views: 10687

Re: help sorting list of filename by its string lenght

foxi, your third code cant be used due to the first line of input is transfered to last line(#183) but also has a blanklines from #91 to 182. those i selected back your second code as working even though i added another two "for /f" scripts to stabilized "?" symbols (if not remov...
by bars143
01 Nov 2013 09:50
Forum: DOS Batch Forum
Topic: help sorting list of filename by its string lenght
Replies: 24
Views: 10687

Re: help sorting list of filename by its string lenght

Dbenham, your REPL.BAT is working great too with only one-liner code and i added code for a result to a file: type test.txt | repl .* "$&??$&" | repl \?\?$ "" | repl .(?=.*\?\?) x|sort|repl .*\?\? "" >>dbenham.txt ================================================...
by bars143
01 Nov 2013 08:44
Forum: DOS Batch Forum
Topic: help sorting list of filename by its string lenght
Replies: 24
Views: 10687

Re: help sorting list of filename by its string lenght

foxi, your second script worked with "_" and "1". and i edited your second script to work with dostips.com's links as specified above. but i did homeworks at many hours and nothing solved as i struggle of what causes that output like "echo off" and a "?" symbo...
by bars143
01 Nov 2013 02:05
Forum: DOS Batch Forum
Topic: help sorting list of filename by its string lenght
Replies: 24
Views: 10687

Re: help sorting list of filename by its string lenght

foxie your code work to the given example but when i included a filenames like below: _ab.mp3 _abcde.mp3 _dostip-abcde.mp3 1abcde.exe 1bc.exe 1dostip-abcde.exe it is scattered. below are output after inclusion of new filename with a "_" or "1" as first character of a filename (it...
by bars143
31 Oct 2013 21:05
Forum: DOS Batch Forum
Topic: help sorting list of filename by its string lenght
Replies: 24
Views: 10687

help sorting list of filename by its string lenght

anyone help and give me a code to sort a list of filenames by its string lenght in a text file? : example of output should be: abc.txt abc.mp3 a_1.exe abcdef.txt abcdef.mp3 abcd_2.exe dostip-abcdef.txt dostip-abcdef.mp3 dostip-abcd_2.exe i will also accept output like this: dostip-abcdef.txt dostip-...
by bars143
20 Oct 2013 06:29
Forum: DOS Batch Forum
Topic: How to create a option menu
Replies: 10
Views: 3165

Re: How to create a option menu

@batch,

this is the output of my window7 32bit to your code above:

Code: Select all

Which option would you like?





its display only one-line and all the rest blank?
maybe we had different cmd.exe ?
by bars143
19 Oct 2013 21:30
Forum: DOS Batch Forum
Topic: delete greater/lesser-than symbols including strings inside
Replies: 8
Views: 2068

Re: delete greater/lesser-than symbols including strings ins

Comment tags are easily solved with an extra REPL. Comments can be multi-line, so the REPL needs the M option. There may be < and > within the comment, so the comments should be removed first. type file.txt|repl "<!--[\w\W]*?-->" "" m|repl "<.*?>" "" >file.tx...
by bars143
18 Oct 2013 00:13
Forum: DOS Batch Forum
Topic: delete greater/lesser-than symbols including strings inside
Replies: 8
Views: 2068

Re: delete greater/lesser-than symbols including strings ins

@foxi, it is ,HTMLAsText , does work. @dbenham, i got your repl.bat but there is one that are not deleted, a tag comment, as shown below-(its 11-lines total) : <!-- var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-11051788-9']); _gaq.push(['_setDomainName', 'pinoyden.com.ph']); _gaq.push(['_trac...
by bars143
17 Oct 2013 17:39
Forum: DOS Batch Forum
Topic: delete greater/lesser-than symbols including strings inside
Replies: 8
Views: 2068

Re: delete greater/lesser-than symbols including strings ins

thanks foxi for links

and i will try and test later.
by bars143
17 Oct 2013 16:37
Forum: DOS Batch Forum
Topic: delete greater/lesser-than symbols including strings inside
Replies: 8
Views: 2068

Re: delete greater/lesser-than symbols including strings ins

Can you save the page as plain text in your web browser? sorry for late reply. and yes ,i can save a page as plain text in a web browser and i can open html by using notepad,notepad2 and notepad++. my purpose of deleting "<--any string-->" is to convert saved html(source code) into a read...
by bars143
17 Oct 2013 04:46
Forum: DOS Batch Forum
Topic: delete greater/lesser-than symbols including strings inside
Replies: 8
Views: 2068

delete greater/lesser-than symbols including strings inside

below are portion of sources code of html: <html> <p>hello world</> <a href=.......>website</a> and of above i only want to remove the following: [code] <html> <p> </> <a href=.......> </a> [code] leaving others intact. but findrepl.bat is difficult for me to learn without the help of an expert. ans...
by bars143
01 Oct 2013 09:10
Forum: DOS Batch Forum
Topic: Help merge strings of every three lines to one line
Replies: 5
Views: 1926

Re: Help merge strings of every three lines to one line

The quotes aren't needed there. This should work if m and n are defined. if %m% gtr 12 echo you typed not in the menu&echo.press enter to go back&pause&goto :top if %m% equ %n% goto :%n%_here I think you actually want to echo the lines into another file - you need to escape & with ^...