Solved

visual c++ simple console application - error

Posted on 1998-07-28
2
166 Views
Last Modified: 2010-04-10
Followed 3 separate books - still can't get the simplest Hello World application to compile without errors. Made the project, set all the options (I hope), been teaching C++ for four years.....please help someone. Error msg is "error spawning cl.exe"
0
Comment
Question by:pswift
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
2 Comments
 
LVL 22

Accepted Solution

by:
nietod earned 50 total points
ID: 1168869
cl.exe is the compiler program.  The VC++ IDE (integrated development Environment) runs this seperate program to do the compile.  This sounds like it couldnt  find the compiler.  Is your path set up right?  Is VC++ newly installed?
0
 
LVL 22

Expert Comment

by:nietod
ID: 1168870
If you are running the compiler from the command line (DOS prompt) or from a batch file you need to make sure the path and other environment variables are set correctly.  This is done by running a batchfile called VCVARS32.BAT.  It should be in one of the VC directories.

If you are running the compiler from within the graphical IDE of VC++, then you need to make sure that VC++'s paths are set correctly.  To do this go to "Tools" menu->"Options" item.  In the dialog that appears, select the "Directories" tab.  In "show directories for:" select "executable files".  Then look at the list of directories and make sure that there is one listed for the BIN directory, like "C:\PROGRAM FILES\DEVSTUDIO\VC\BIN"  (You path may need to be different than mine.)
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: SunnyDark
This article's goal is to present you with an easy to use XML wrapper for C++ and also present some interesting techniques that you might use with MS C++. The reason I built this class is to ease the pain of using XML files with C++, since there is…
Written by John Humphreys C++ Threading and the POSIX Library This article will cover the basic information that you need to know in order to make use of the POSIX threading library available for C and C++ on UNIX and most Linux systems.   [s…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.

622 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question