Hello All,
I've been working on an addin that modifies certain project configuration items of all the projects in the currently loaded solution.
My method consisted of the following :
Project prj;
Configuration config;
Properties configProps;
Property prop;
string intermediate, output, preprocessor;
if (_applicationObject.Solution.Projects.Count > 0)
{
int project_count = _applicationObject.Solution.Projects.Count;
for (int i = 1; i <= project_count-1; i++)
{
prj = _applicationObject.Solution.Projects.Item(i);
config = prj.ConfigurationManager.ActiveConfiguration;
configProps = config.Properties;
prop = configProps.Item("OutputDirectory");
prop = configProps.Item("PreprocessorDefinitions");
}
}Except, the call to retrive the "PreprocessorDefintions" property throws an exception. What I'm trying to do is get the value of the Configuration Properties->C\C++->Preprocessor:Preprocessor Definitions.
Can anyone see what I'm doing incorrectly?
Thanks.