VCProject.AddRuleDefinition Method (String, String, Boolean)
Adds a rule to the project so that it is available as an IVCRulePropertyStorage.
Assembly: Microsoft.VisualStudio.VCProjectEngine (in Microsoft.VisualStudio.VCProjectEngine.dll)
bool AddRuleDefinition( string bstrRuleFilePath, string bstrContext, bool bPersistInProject )
The path to a XAML file that contains a rule. May be a full path or relative to the project.
A semicolon-delimited list of contexts in which this rule applies.
Specify true to add the rule to the project permanently, or false to add the rule only until it is unloaded.
Return ValueType: System.Boolean
true if the rule was actually added to the project; false if the rule was already defined in the project.
This method adds a PropertyPageSchema item to the project file. No condition is attached to the added item.
To read the rule just added, browse through Rules for any configuration.