Basic DOS commands..

Associate
Joined
25 Apr 2004
Posts
870
Location
Devon
Hi anyone,

I'm having some trouble with Dos, I'm trying to use a program that has to be run from command. Basically I want to navigate to Program Files, but when I type cd C:\"Program Files" it says 'too many parameters - Program, and if I do it without the quotes it says too many parameters - Files.. what am I doing wrong here?

Thanks
Felix
 
Remove the " from the command line

Is the file in program files or program files\util?

cd\program files
or
cd\program files\util

then
nameoftheexe
 
Code:
cd "C:\Program Files"
should work

Anything with a space in it, just put quotes around the path

A site I've found useful in the past is http://www.computerhope.com/msdos.htm

Alternatively, assuming you're doing this from windows, open the command prompt and also the folder with the exe. Then drag the exe in to the command prompt window, and hit enter :)
 
Last edited:
Doing it from Windows Vista, tried to drag the exe in but it won't go.

cd C:\"Program Files" gets error 'parameter format not correct - "C:\Program'

removing quotes and doing cd\Program Files gets 'Too many parameters - Files'
 
You need to put quotes around the whole path, including the drive letter, not just the directory.
 
To change directory, and you're working in C:\, you do

cd \program files

Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\Documents and Settings\Administrator>cd \program files

C:\Program Files>
 
Last edited:
AlwaysOnTheRun said:
Doing it from Windows Vista, tried to drag the exe in but it won't go.

cd C:\"Program Files" gets error 'parameter format not correct - "C:\Program'

removing quotes and doing cd\Program Files gets 'Too many parameters - Files'

try: cd "C:\Program Files"
 
AlwaysOnTheRun said:
Doing it from Windows Vista, tried to drag the exe in but it won't go.

cd C:\"Program Files" gets error 'parameter format not correct - "C:\Program'

removing quotes and doing cd\Program Files gets 'Too many parameters - Files'


you're quoting the wrong place..

Evil-Penguin said:
You need to put quotes around the whole path, including the drive letter, not just the directory.


cd "c:\program files"

that'll do it...


-in 2k/xp dos, just typing..

cd c:\program files

works fine
 
Or use old dos 8 character limits:
cd progra~1 to get to Program Files
cd docume~1 to get to DOcuments & Settings

or use asterisks

cd Prog*
cd Doc*
 
Back
Top Bottom