Setting File Properties

See Also 

When you set the project properties for your C or C++ project, the relevant properties apply to all folders and files in the project.

By default, a file inherits the include directories, preprocessor definitions, and C/C++ standard from the project. You can choose to have a file not inherit these properties.

To modify a file property:

  1. In the Projects window, right-click the file and choose Properties.
  2. In the Project Properties dialog box, select the configuration for which you want to set a property.
  3. Select a node in the left panel and modify the property using the text fields, drop-down lists, checkboxes, and buttons in the right panel.

You can set the following properties for a specific file:

Include Directories and Headers. Type the absolute or relative path to the directories containing headers for your project, or click the button to browse to the directories and add them. On the file browser dialog box, you can specify Absolute or Relative path.

Preprocessor Definitions. Add definitions for macros used by the project. Click the text field or the button to open the Preprocessor Definitions dialog box to add definitions.

Preprocessor Undefined. Add definitions for macros used by the project. Click the text field or the button to open the Preprocessor Definitions dialog box to add definitions.

C Standard. Specifies whether project sources should be parsed as C89 code or C99 code.

C++ Standard. Specifies whether project sources should be parsed as C++98 code or C++11 code.

 

See also
  Setting C and C++ Compiler Options
C/C++ Project Properties Dialog Box: Compiler (General)

Copyright © 2013, Oracle and/or its affiliates. All rights reserved.