Computing.Net > Forums > Programming > CALL a program with a Batch file

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

CALL a program with a Batch file

Reply to Message Icon

Name: coolduderyan07
Date: February 13, 2006 at 08:35:53 Pacific
OS: XP Home ed. service pck 1
CPU/Ram: Pentium 4 512 mb
Product: Dell 2002
Comment:

Hey,
Just have a quick question,
My batch file won't call the program I tell it to. I tell it CALL C:\programfiles\blah\blah.exe and nothing happens.. any ideas of what is wrong?



Sponsored Link
Ads by Google

Response Number 1
Name: Mechanix2Go
Date: February 13, 2006 at 08:52:53 Pacific
Reply:

A couple possibilities.

C:\programfiles\blah\blah.exe

may be a wrong path. If it's actually:

C:\program files\blah\blah.exe

you will need to put it in double quotes:

"C:\program files\blah\blah.exe"

Or blah.exe may not be there.

"nothing happens.."

Not often that NOTHING HAPPENS. If it's not found, you will usually get the NT equivalent of "bad command".

One way to check is to put a PAUSE after the problem line.

Finally, you don't need to CALL an exe. CALL is for batch files.


If at first you don't succeed, you're about average.

M2


0

Response Number 2
Name: coolduderyan07
Date: February 13, 2006 at 09:47:39 Pacific
Reply:

Alright I just figured out how to do it...
Lets say I wanted to open up call of duty multiplayer.. Just in case Its not in that path it will find it in C: drive

c:
cd \
cd "Program Files\call of duty game of the year edition"
CODMP.exe

Thanks anyway



0

Response Number 3
Name: CWoodward
Date: February 13, 2006 at 18:17:29 Pacific
Reply:

Or, you could do it it one line:

START "C:\Program Files\call of duty game of the year edition\CODMP.exe"

"If it jams, force it. If it breaks, it needed replacing anyway."
-Murphy's Laws


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More


C# vs C++ dos window disappears in ...



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: CALL a program with a Batch file

Make an exe with a batch file and.. www.computing.net/answers/programming/make-an-exe-with-a-batch-file-and/17595.html

Open IE from a batch file www.computing.net/answers/programming/open-ie-from-a-batch-file/14896.html

Closing A Program With BASIC/Batch www.computing.net/answers/programming/closing-a-program-with-basicbatch/13222.html