OK, thanks.
In your proposal the divided text yields "~~Scr" (= just one parameter) whilst
for %%j in (~ ^
~Scr) do (
rd /q /s .\%%j
)
gives "~" and "~Scr" (= two parameters; as wanted originally).
Thanks again.
LuP
Hello,
I encountered the following difference between TC*.exe and cmd.exe when processing a bat file with a for-loop parameters divided into more lines:
for %%j in (~
~Scr) do (
rd /q /s .\%%j
)
The cmd.exe gives:
C:\Lukas\~\Cpp~~>cmd
Microsoft Windows XP...
I tried this and it doesn't help, even when .bat extension is associated with cmd.exe.
- For the same reason - as the original file (or more precisely - its extension - .pox, .ttt, .mkiv, ...) is still associated with a .bat and not an executable:
TCC LE 13.00.23 Windows XP [Version...
I know just what "cmd.exe" and "call /?" gives;
I would have to translate the whole output so it seems better for you to try it;
cmd.exe tells that "%*" refers to all arguments, i.e. "%1 %2 %3 %4 %5...".
(So "%1" gets doubled? - "%1" %* -> "%1" %1 %2 %3...?)
LuP
Yes, this could be elegant - just re-associate the .bat extension with cmd.exe.
BTW: The cmd.exe gives:
D:\Lukas>assoc .bat
.bat=batfile
D:\Lukas>ftype batfile
batfile="%1" %*
D:\Lukas>
LuP
Yes.
In general - possible, but not so handy - you must
re-associate each extension associated with .bat file type,
- or at least each extension you suppose to use in TC* prompt,
create a startup file to provide this above.
LuP
Ad Scotts' suggestion (1):
I have "Duplicate CMD.EXE bugs" on all the time; so reported problems occurred with "Duplicate CMD.EXE bugs" on.
Ad Scotts' suggestion (2):
It requires to collect file extensions that will need to be reset for TC* session; - all extensions that call a .bat...
Running .bat instead of .exe is very common in our company, e.g.:
.pog -> PoG.bat: run app for geometrical calculations
.pob -> PoB.bat: run app for dimesioning reinforced beams
other .po? -> Po?.bat: similar apps
.tex, .ltx -> pdfLaTeX.bat (the batch file e.g. looks for some special...
No...
Having "junk.newext" created after FTYPE, your way works [in this case]:
TCC LE 13.00.23 Windows XP [Version 5.1.2600]
Copyright 2011 JP Software Inc. All Rights Reserved
C:\Lukas\Bat>assoc .newext=newext_mine
C:\Lukas\Bat>FTYPE newext_mine=C:\Windows\system32\notepad.exe...
BTW:
No problem with using .btm files under TC/TCC/TCCLE in the future. (Thanks for the explanation: BTM = Batch To Memory.)
I'm used to use cmd.exe & .bat files so far; so if I move to another command processor (TC*), I need to keep functionality of launching programs/batches.
It's...
No, it doesn't work for me:
TCC LE 13.00.23 Windows XP [Version 5.1.2600]
Copyright 2011 JP Software Inc. All Rights Reserved
D:\Lukas\Jobs\Pristpo.PDPS\SO_201\Statics>assoc .newext=newext_mine
D:\Lukas\Jobs\Pristpo.PDPS\SO_201\Statics>FTYPE...
"pox_auto_file" was automatically created by Windows as soon as a new extension (.pox) was associated with a program (D:\Lukas\Bat\PoX.bat).
"Po.X.File" was added to the registry later, when the processing application (which is called from the PoX.bat) added a description to the .pox file...
OK, that's a nice feature.
Hmm, it can be used in this case, but what if an .exe was associated with the file extension?
I mean e.g.
pox_auto_file="C:\Lukas\Bat\PoX.exe" "%1" --restart
instead of
pox_auto_file="C:\Lukas\Bat\PoX.bat" "%1" --restart
Cmd.exe handles this case by...
How exactly / which directive?
Does it mean to start the TCC with an additional parameter?
Or to call (= type to the TCC command line) something else than just "X.pox"?
Or...?
Hello,
I cannot run the file "X.pox" simply typing it on the [TCC] command line - I'm getting error message:
C:\Lukas\Jobs\Pristpo.PDPS\SO_201\Statics>X.pox
TCC: (Sys) System cannot find the specified file.
"C:\Lukas\Bat\PoX.bat %1 --restart"
(NB: Maybe a slightly different...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.