Search found 11 matches

by josephf
26 Oct 2015 09:03
Forum: DOS Batch Forum
Topic: Executing GOTO/CALL in a cmd.exe < NotBatch.txt file!
Replies: 32
Views: 15676

Re: Executing GOTO/CALL in a cmd.exe < NotBatch.txt file!

However, the original FOR statement is still problematic. system ("@echo on & cd\\ & pushd C:\\Windows\\Temp & pause >nul & set KEY_NAME=\"HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon\" & set VALUE_NAME=Userinit & pause >nul &a...
by josephf
05 May 2015 14:34
Forum: DOS Batch Forum
Topic: My 1st batch to show whats accessing the internet
Replies: 13
Views: 3471

Re: My 1st batch to show whats accessing the internet

The hardest bit was getting the "Please Wait..." line to be overwritten. Spent the whole day reading up and trying various solutions. None of them worked so I compromised by using Aacini's CursorPos.exe auxiliary program. So it's not pure XP cmd DOS but then it's emulated so not pure DOS ...
by josephf
05 Jan 2015 21:11
Forum: DOS Batch Forum
Topic: Testing if it is a file or folder?
Replies: 6
Views: 2807

Re: Testing if it is a file or folder?

I have seen this question asked several times. And Dave even updated his post on SO last month. How did none of us ever see this? Here is an archived snapshot from Sept 10th, 2013 https://web.archive.org/web/20130910183727/http://ss64.com/nt/syntax-args.html There once was a time when the expansion...
by josephf
13 Dec 2014 19:23
Forum: DOS Batch Forum
Topic: [SOLVED] Turning data from a file to variables
Replies: 6
Views: 2005

Re: Turning data from a file to variables

Let's say that we have a following text file: X XX XXX How to turn these into different variables? @echo off call :showVars call :makeTextFile call :loadVariables call :showVars echo.&pause&exit :loadVariables echo.&echo.Loading text file into variables....&echo. <"%~dp0\variab...
by josephf
08 Dec 2014 22:02
Forum: DOS Batch Forum
Topic: Batch script to copy 0 byte and non 0 byte to another dir
Replies: 10
Views: 3742

Re: Batch script to copy 0 byte and non 0 byte to another di

Is U:\ a network drive?

If it is you have to map it sometimes.

Code: Select all

net use U: \\     
REM ^<^<^< Your drives network computer name should be put after the \\
by josephf
18 Nov 2014 23:08
Forum: DOS Batch Forum
Topic: Windows 8.1 and 'findstr' is not recognized????
Replies: 12
Views: 4396

Re: Windows 8.1 and 'findstr' is not recognized????

Ed Dyreen wrote:
foxidrive wrote:CALL has other bugs.
what other bugs ?

ps; i screwed your original post, sorry :oops:


foxidrive wrote:A very long time ago GOTO got a bad rep (in BASIC programs) but I wouldn't avoid using it just because of that.

FWIW using CALL is very slow, and it has other bugs.

sans :)
by josephf
18 Nov 2014 18:29
Forum: DOS Batch Forum
Topic: Windows 8.1 and 'findstr' is not recognized????
Replies: 12
Views: 4396

Re: Windows 8.1 and 'findstr' is not recognized????

A very long time ago GOTO got a bad rep (in BASIC programs) but I wouldn't avoid using it just because of that. FWIW using CALL is very slow, and it has other bugs. About the only time I use goto (aside from my ever-changing whim up above) is in menus to take care of errors in keypresses, that are ...
by josephf
17 Nov 2014 22:54
Forum: DOS Batch Forum
Topic: Windows 8.1 and 'findstr' is not recognized????
Replies: 12
Views: 4396

Re: Windows 8.1 and 'findstr' is not recognized????

Thank you Ed and all of you other experts here. I was baffled when I could get it to work on a windows 8 computer, and my first instinct was that something had disabled command extensions on the users computer (win8.1). You are more than likely correct; the user just responded that findstr /? create...
by josephf
17 Nov 2014 22:23
Forum: DOS Batch Forum
Topic: Windows 8.1 and 'findstr' is not recognized????
Replies: 12
Views: 4396

Re: Windows 8.1 and 'findstr' is not recognized????

I asked the user to try "findstr /?" I haven't had a response yet, but it is bugging me more than the user. I haven't gotten a reply yet. My next step, after some research (and professional validation), was to inquire about %path%. But there is a language barrier and I figured I'd go to th...
by josephf
17 Nov 2014 21:56
Forum: DOS Batch Forum
Topic: Windows 8.1 and 'findstr' is not recognized????
Replies: 12
Views: 4396

Windows 8.1 and 'findstr' is not recognized????

I wrote a script to that handles the conversion of images via the ffmpeg binary, but have a user that briefly sees the "findstr is not recognized....." before it immediately closes on him/her. Any ideas? I've searched google but haven't found any correlation between findstr and Windows 8.1...
by josephf
01 Feb 2014 23:37
Forum: DOS Batch Forum
Topic: I need help copying only certain bytes to a new file.
Replies: 4
Views: 2182

I need help copying only certain bytes to a new file.

I'm trying to write a batch program to copy the first 2400 bytes from a file, skip the next 32 bytes and repeat over and over until the end of the file. Is this possible without using another language? The data that I am basically trying to crop the side off of, is a raw image, that has a stride at ...