VS Project Property Manage

The concept: Project Property and Property Sheet.

  • Project Property: Project properties, is a property of the preparation of your current project, save the file in your project's preparation, rojectName.vcxproj in.
  • Property Sheet: attribute table, the properties available for the preparation of multiple projects, you can create your own add attributes preparation, you can also use the system default attribute table stored in .props to expand the name of the file. And the attribute table (Property Sheet) was added and the management is set in the Property Manager.

The default attribute table meaning to Debug | x64 configuration example,

  1. Microsoft.Cpp.x64.user:
    the default attribute table, the full path,
    C: \ the Users \ horswing \ AppData \ Local \ in the Microsoft \ MSBuild \ v4.0 \ Microsoft.Cpp.x64.user.props
    project is created, the default have this property sheet. Double-click to modify (right effect on the solution explorer project name -> property agreement), remove the right-election and removal.
  2. Application:
    indicates that the project is generating an "application" (not a DLL or LIB). In the Property Manger where this can not be changed, so you will find double-click, the page that appears is gray, and only property right option.
    Where you change it? solution explorer, the Project Properties -> gerneral -> Project Defaults - > Configuration Type.
  3. Unicode Support and Core Windows Libraries
    and Application items like these two also "could not try to change" and to change, respectively, Project Properties -> gerneral -> Project Defaults in the Character Set and Use of MFC modified.

Property inheritance

Property project is hierarchical. Each layer will inherit the value of the previous layer, but may be inherited values ​​explicitly overridden by setting properties. Here is the basic inheritance (inheritance tree):

  1. MSBuild CPP toolset from default settings (.. \ Program Files \ MSBuild \ Microsoft.Cpp \ v4.0 \ Microsoft.Cpp.Default.props, it is introduced into ProjectName.vcxproj file).
  2. Property sheets (attribute table), the attribute table is set in the Property Manager.
  3. Project file ProjectName.vcxproj. (You can override the default values ​​set in the property sheet).
  4. Metadata for each item.

Digression, which we found there are three places you can set project properties:

  1. Property Manager in the attribute table (can be modified on the default attributes table or their new one);
  2. solution explorer, the project properties;
  3. In the code changes: for example, macro definitions, additional libraries.

Note: There is provided a conflict, 3 cover 2, a cover 2.


Reference article: https://msdn.microsoft.com/en-us/library/669zx6zc.aspx

Guess you like

Origin www.cnblogs.com/hjbf/p/11994865.html