PRB: "Bad command or file name" Error When RC.EXE Not Found |
Q129415
1.50 1.51 1.52 WINDOWS kbtool kbprb
The Visual Workbench is unable to run the resource compiler, RC.EXE. The
output windows shows results similiar this:
Compiling resources...
Bad command or file name
Compiling...
<drive>:\<path>\<filename>.cpp
Linking...
Binding resources...
Bad command or file name
Creating browser database...
<filename>.EXE - 0 error(s), 0 warning(s) There is a problem with the AUTOEXEC.NT file that results in the removal of <msvc>\BIN from the PATH environment variable, where <msvc> is the directory in which Visual C++ is installed.
Remove or correct the PATH statement in the AUTOEXEC.NT file. If the
existing PATH contains <msvc>\BIN, you can remove the PATH statement from
the AUTOEXEC.NT. If you want to add the existing PATH to the AUTOEXEC.NT,
add %PATH% as the last item on the PATH environment variable in the
AUTOEXEC.NT. Otherwise, add <msvc>\BIN to the PATH in the AUTOEXEC.NT file.
NOTE: AUTOEXEC.NT is located in the <winnt>\SYSTEM32 directory, where
<winnt> is the directory in which Windows NT is installed.
This behavior is by design. The error message notifies you that RC.EXE was not found.
Most of the command line tools (compiler, linker, and so on) that ship with
Visual C++ versions 1.5x are native Win32-based applications that use the
DOSXNT DOS-extender to permit them to run under MS-DOS. In the Windows NT
environment, they run as native 32-bit applications without the
DOS-extender. RC.EXE is an exception, in that it is a 16-bit tool.
When RC.EXE is spawned by the development environment during a build,
Windows NT determines that RC.EXE is an MS-DOS application and prepares to
run an MS-DOS application. One of the steps in this preparation is to run
the AUTOEXEC.NT batch file.
If <msvc>\BIN is on the existing PATH, a PATH statement is in AUTOEXEC.NT,
and neither <msvc>\BIN nor %PATH% are part of that statement, then RC.EXE
will not be found.
Additional query words: 1.50 3.50 3.51
Keywords : kb16bitonly
Issue type :
Technology : kbVCsearch kbAudDeveloper kbvc150 kbVC151 kbVC16bitSearch kbVC152
|
Last Reviewed: June 4, 2001 © 2001 Microsoft Corporation. All rights reserved. Terms of Use. |