Search found 43 matches
- 07 Mar 2013 02:58
- Forum: DOS Batch Forum
- Topic: File format help
- Replies: 1
- Views: 3380
File format help
I basically have this file: div style='width:1px;height:12px;' opalescence opulent paragon pellucid ominous ostracize perfunctory peremptory pariah pall obstreperous parsimonious olfactory odious obfuscate ostentatious obtrusive opprobrium parlance pecuniary penurious nettle obviate overture obdurat...
- 04 Aug 2012 21:47
- Forum: DOS Batch Forum
- Topic: Findstr question
- Replies: 3
- Views: 4217
Re: Findstr question
Your code works just fine, but what I need is for there to be a message printed on the screen if the search string (%%d) is not found in the file.
- 04 Aug 2012 21:30
- Forum: DOS Batch Forum
- Topic: Findstr question
- Replies: 3
- Views: 4217
Findstr question
Maybe I am missing something simple, but I would like to use findstr to search for a line in a file, and parse that line to give output (a for loop works). I have that down, but I would also like the script to alert the user if no match is found. So far I have this: for /f "delims=." %%f i...
- 23 Jun 2012 23:23
- Forum: DOS Batch Forum
- Topic: Findstr for blank lines
- Replies: 5
- Views: 16495
Re: Findstr for blank lines
findstr /n /r /v /c:"[^ ]" test.txt
Works perfectly! I need to keep working on this findstr stuff, idk why it seems to confuse me so
Thanks for the help guys
- 23 Jun 2012 18:12
- Forum: DOS Batch Forum
- Topic: Findstr for blank lines
- Replies: 5
- Views: 16495
Re: Findstr for blank lines
use regular expressions for the nonvisible
How would you do that?
I have tried things like
Code: Select all
findstr /n /r "^[\ ]*" file.txt
but I can't seem to get them to work
- 23 Jun 2012 16:09
- Forum: DOS Batch Forum
- Topic: Findstr for blank lines
- Replies: 5
- Views: 16495
Findstr for blank lines
I'm simply trying to find a findstr command expression that will echo back all blank lines of the file with their line number (including lines that consist of all nonvisible characters) So far I have: findstr /n /v /r "^." "file.txt" But this will not echo back a line that has sp...
- 23 Jun 2012 08:53
- Forum: DOS Batch Forum
- Topic: Searching for redirection chars with findstr
- Replies: 4
- Views: 6422
Re: Searching for redirection chars with findstr
Strange.. the original solution seemed to work, but maybe I'm crazy. I switched over to this new solution.
My original requirements were simply that the line did not begin with a '/', and the line did not contain 'illegal characters'.
Thanks again
My original requirements were simply that the line did not begin with a '/', and the line did not contain 'illegal characters'.
Thanks again
- 22 Jun 2012 22:54
- Forum: DOS Batch Forum
- Topic: Searching for redirection chars with findstr
- Replies: 4
- Views: 6422
Re: Searching for redirection chars with findstr
Thank you very much for your response, I hadn't known very much about findstr but now I have a much better understanding after deciphering your alternative solutions. Also thanks for the errorlevel alternative I found this solution suited my needs perfectly: findstr /r "^[^/\\:*?\"\"<...
- 22 Jun 2012 17:53
- Forum: DOS Batch Forum
- Topic: Searching for redirection chars with findstr
- Replies: 4
- Views: 6422
Searching for redirection chars with findstr
Here is problematic code: for /f "tokens=* eol=/ delims=" %%a in (format.txt) do ( echo %%a|findstr /r "[/\:*?^"^<^>^|]" > nul if errorlevel 1 ( set "format=%%a" ) else ( cls echo Your format contains illegal characters! echo Rename not completed. pause exit ) ) ex...
- 01 Jun 2012 22:28
- Forum: DOS Batch Forum
- Topic: how to replace all occurrences of ;;;; with ; in a string
- Replies: 36
- Views: 30322
Re: how to replace all occurrences of ;;;; with ; in a strin
Well my apologies...
I'll just let you guys deal with the problems
I'll just let you guys deal with the problems
- 01 Jun 2012 12:06
- Forum: DOS Batch Forum
- Topic: how to replace all occurrences of ;;;; with ; in a string
- Replies: 36
- Views: 30322
Re: how to replace all occurrences of ;;;; with ; in a strin
Call me lazy, but I didn't want to read 2 pages of comments, so I'm posting this solution w/o knowing if it has been suggested already @echo off setlocal enabledelayedexpansion set "string=,,,value1,value2 opt,,,value3,,value4 opt,,,value5,,,,," for /l %%a in (1,1,8) do set "string=!s...
- 26 Apr 2012 18:11
- Forum: DOS Batch Forum
- Topic: [Solved] Start CMD With Inactive Window
- Replies: 9
- Views: 10290
Re: [Solved] Start CMD With Inactive Window
At least it will if the CMD windows are set to appear in the same position, which is how I have cmd windows set to appear.
How would one go about changing that setting (I would like to)
- 26 Apr 2012 18:09
- Forum: DOS Batch Forum
- Topic: Batch Games
- Replies: 31
- Views: 74672
Re: Batch Games
I made this game a while ago, and it's not finished, but I would be curious to see if it could run on other people's computers There are quite a few files and a few external executables (taken from a site called lingubender.com which is no longer online) Anyway most info is in instructions.txt, but ...
- 26 Apr 2012 17:56
- Forum: DOS Batch Forum
- Topic: hide entered password with astrics
- Replies: 11
- Views: 21975
Re: hide entered password with astrics
Cat, you could do this in the batch file: (I think)
but you would need to only output the password with the exe, you currently output a space before the password aswell
Code: Select all
for /f %%a in ('password.exe') do set "password=%%a"
but you would need to only output the password with the exe, you currently output a space before the password aswell
- 24 Apr 2012 19:58
- Forum: DOS Batch Forum
- Topic: Encoding / Decoding
- Replies: 8
- Views: 13294
Re: Encoding / Decoding
pretty cool I like that yours allows for text passwords, I might get around to making another that can use a text password
Also, I had no idea you could do this very cool!
Also, I had no idea you could do this very cool!
Code: Select all
!endpattern: =! | clip