Friday, March 12, 2010

Too many arguments in command line.

Too many arguments in command line.

The magic is in the help, more /?, which contains the (oddly) helpful line "Switches can be present in the MORE environment variable."

Apparently Windows' default is to add the '/e' switch to more.com somewhere in the registry. I don't know what I did, but suddenly the command
more mytextfile.txt
produced the complaint "Too many arguments in command line."

I restored the behavior to which I was accustomed by adding the environment variable MORE with the parameters
/e

I also tossed in /c and /s for good measure:
/c - clear screen before displaying page
/s - squeeze multiple blank lines into a single line

1 comment: