What to Do If CodeBlocks Repeatedly Closes on Mac
  • First, as always, make sure you save your work frequently.
  • Second, try the suggestion here and your problem should be solved.

How To Open CodeBlocks and Create a C++ File

Getting Started in Code::Blocks

  • Search for the Code::Blocks Icon on the desktop and double-click. If you can't locate it on the desktop, look under the Start Menu for Windows or in your Applications folder on the Mac.  
  • Code::Blocks should open and display the following start screen:

  • Click on File in the top menu. Hover over New. Hover over File... and select it.

  • Select C/C++ source file from the options.
  • A popup up will appear welcoming you to the file wizard. Click next.

  • You will have a choice between creating a C file and a C++ file. Choose C++ and click the Next button:

  • Now it is time to choose where to save your file. Click on the box located next to the "Filename with full path:" text box, as shown below:

  • You will now have a choice as to where to save your file and what to name it. Make sure to give your file a name with the extension .cpp (For example hello.cpp). You may wish to create a separate folder to save all C++ files for this class.

  • Press the save button and you will be ready to start coding!