Thread: VC++ Express: The system cannot find the specified path

  1. #1
    Registered User
    Join Date
    Feb 2008
    Posts
    30

    VC++ Express: The system cannot find the specified path

    Hi,

    Recently I am unable to compile programs with Visual C++ Express 2005. It work fine before. When I try to compile code I get the error message:

    Code:
    The system cannot find the specified path.
    I am not sure when this started to happen, but I tried to install Visual Studio 2005 Professional recently which might have caused this.

    Does someone know what causes the error, and how I can solve it?

    Thanks


    This is the exact error message from Visual Studio:


    Code:
    ------ Build started: Project: program, Configuration: Debug Win32 ------
    Compiling...
    stdafx.cpp
    Compiling...
    program.cpp
    Compiling manifest to resources...
    Linking...
    Embedding manifest...
    Het systeem kan het opgegeven pad niet vinden.
    Project : error PRJ0002 : Error result 1 returned from 'C:\WINNT\system32\cmd.exe'.
    Build log was saved at "file://c:\Documents and Settings\Tex\Bureaublad\ziek\program\program\Debug\BuildLog.htm"
    program - 1 error(s), 0 warning(s)
    ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

  2. #2
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    It seems some file is missing or PATH is incorrect maybe? That's what it sounds like to me.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  3. #3
    Woof, woof! zacs7's Avatar
    Join Date
    Mar 2007
    Location
    Australia
    Posts
    3,459
    Post what "echo %PATH%" says (from a command prompt).

    Also, this should be moved... doesn't really live here.

  4. #4
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Well actually, you could just get away with typing "path" at the cmd prompt.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  5. #5
    Registered User
    Join Date
    Feb 2008
    Posts
    30
    Thanks for your help.

    I have changed the path, and the error is gone, but now the following error message occurs:

    Code:
    Project : error PRJ0003 : Error spawning 'cmd.exe'.
    This is the output from "path":

    Code:
    PATH=C:\Program Files\Microsoft Visual Studio 8\Common7\IDE;C:\Program Files\Mic
    rosoft Visual Studio 8\VC\BIN;C:\Program Files\Microsoft Visual Studio 8\Common7
    \Tools;C:\Program Files\Microsoft Visual Studio 8\Common7\Tools\bin;C:\Program F
    iles\Microsoft Visual Studio 8\VC\PlatformSDK\bin;C:\Program Files\Microsoft Vis
    ual Studio 8\SDK\v2.0\bin;C:\WINNT\Microsoft.NET\Framework\v2.0.50727;C:\Program
     Files\Microsoft Visual Studio 8\VC\VCPackages;C:\WINNT\system32;C:\WINNT;C:\WIN
    NT\System32\Wbem;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\Microsoft
     SQL Server\80\Tools\Binn\;C:\Program Files\Common Files\Adobe\AGL;C:\Program Fi
    les\ATI Technologies\ATI.ACE\;C:\Program Files\Microsoft SQL Server\90\Tools\bin
    n\

  6. #6
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Is there a cmd.exe in c:\windows\system32\ ? (That's where it usually lives).

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  7. #7
    Woof, woof! zacs7's Avatar
    Join Date
    Mar 2007
    Location
    Australia
    Posts
    3,459
    I assume you're on W2K from your path?

    Quote Originally Posted by from your path
    C:\WINNT\system32;C:\WINNT;C:\WIN
    NT\System32
    If not, then they're wrong.

  8. #8
    Registered User
    Join Date
    Feb 2008
    Posts
    30
    Yes, I am using Windows 2000 and the cmd is in system32.


    When I choose to load the Visual Studio command prompt from Visual studio a cmd is loaded instead of the Visual Studio command prompt.


    Is there a way to revert my settings to the default Visual Studio settings pherhaps?

    Thanks

  9. #9
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Tools -> Import/Export settings
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  10. #10
    Registered User
    Join Date
    Feb 2008
    Posts
    30
    Arrrgh. I did that and now the error
    Code:
    The system cannot find the specified path.
    is back again. lol

  11. #11
    Registered User
    Join Date
    Feb 2008
    Posts
    30
    When I try to load the Visual Studio command prompt from Visual Studio I get an error message about that vcvars32.bat is not recognized.

  12. #12
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Have you tried reinstalling? These errors shouldn't happen.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  13. #13
    Registered User
    Join Date
    Feb 2008
    Posts
    30
    I did that this morning. Unfortunatly it did not help.

  14. #14
    Registered User
    Join Date
    Feb 2008
    Posts
    30
    I am going to restore my OS from a backup I have. I have uninstalled all versions of Visual C++, removed the belonging folders and reinstalled Visual C++ but it all did not help.

    Thanks all for your suggestions.

    Regards,

    Ben

  15. #15
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    It's weird though, because I've never had such a problem.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. can .exe find the path to a file?
    By Unregistered in forum Windows Programming
    Replies: 4
    Last Post: 06-12-2002, 01:08 PM
  2. Path problems
    By pdstatha in forum C Programming
    Replies: 0
    Last Post: 03-28-2002, 07:10 AM
  3. find in system()
    By Unregistered in forum Linux Programming
    Replies: 2
    Last Post: 03-25-2002, 08:49 AM
  4. Won't Return pointer, i can't find why...
    By ss3x in forum C++ Programming
    Replies: 2
    Last Post: 02-28-2002, 08:50 PM
  5. Number system base M, print numbers N digits wide...
    By biterman in forum C Programming
    Replies: 12
    Last Post: 11-19-2001, 04:31 AM