Menu

"Cannot save file xxxxx"

WTommy
2007-10-07
2012-09-26
  • WTommy

    WTommy - 2007-10-07

    I have installed DEV C++ (version 4.9.9.2).
    And when i save the cpp file, it will accidentally appear the error warning "Cannot save file xxx.cpp". After I click the "OK" button, it will not appear again and work well. My system is Windows XP SP2 (English version).

    Does anyone why it is ? Thanks...

    PS: reinstalling the software doesn't work.

     
    • Anonymous

      Anonymous - 2007-10-20

      Aaaaarrrrrrgggggghhhhhhhh! The thread titled "PLEASE READ BEFORE POSTING A QUESTION" explicitly warns about not using paths with spaces. As the title implies you are expected to read it FIRST. Would have saved you a lot of time.

      Clifford

       
    • WTommy

      WTommy - 2007-10-21

      Thanks, I'll try that :)

       
    • Martian Man

      Martian Man - 2007-10-13

      Tommy,
      Try saving the file as a C source file (.c) instead of a C++ source file (.cpp).
      If the same thing appears try saving header files or resource files, but save the header files as .h not .hpp.
      And here's another tip: don't type the extension in the box where you type the file name (for example instead of typing FileName.c just type FileName it will automatically save as a C source file.

       
      • WTommy

        WTommy - 2007-10-17

        Thanks for your reply!
        I CAN save the file, but it appears the WARNING frame accidentally.

        As a matter of fact, when i save the file for the first time, i always type the extension ".cpp" into the box.
        Maybe that will lead the WARNING.

        Does anyone encounter the situation such like me ? How to avoid the WARNING frame ?

         
        • Osito

          Osito - 2007-10-17

          What exactly does the warning say?

           
      • Anonymous

        Anonymous - 2007-10-14

        Why?

         
    • WTommy

      WTommy - 2007-10-18

      It says "Cannot save file C:\Docunments and Settings\WTommy\Desktop\Temp_code\JLU\DD.cpp"

      I doubted that it is related with my English Version System WinXP SP2. But I can't find the exact reason.

       
      • Osito

        Osito - 2007-10-18

        It could be the spaces in the path. I've seen that before too, where it gives me a warning but does still save the file. For Dev-Cpp it is highly recommended that you do not put your project in a path that contains spaces, or use spaces in your source filenames or output filename.

         
    • WTommy

      WTommy - 2007-10-20

      To Osito:
      Thanks a lot for your reply.

      But when I used Chinese version WinXP SP2 before, I usually saved the cpp files into the Desktop whose path also contains a space between "Documents and Settings" and the Error Frame had ever not appreared yet.
      I don't know why :)

      Thank you. I will try to save the files to a path without spaces.

       
      • Osito

        Osito - 2007-10-20

        It's funny like that. Sometimes spaces in the path are fine, other times they cause warnings, errors, and unexpected behavior.

         

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.