DMillerNCR

In VC7.1 in the property pages for a project, if I entered a relative path for an include file on the "Additional Include Directories", then the IDE showed valid paths relative to the project file. In VC8, relative paths are all relative to some path in the install directory NOT my project. How can I get the VC7.1 behavior This new behavior is not intuitive. I never place my files relative to the install directory.

Re: Visual C++ General Change in behavior of properties from VC7.1 to VC8

nobugz

Try using the $(ProjectDir) macro. For example $(ProjectDir)..\foldername




Re: Visual C++ General Change in behavior of properties from VC7.1 to VC8

DMillerNCR

Thanks! This looks like a bug in the auto completion dialog, because it compiles with just ..\some-dir rather than $(ProjectDir)..\some-dir.



Re: Visual C++ General Change in behavior of properties from VC7.1 to VC8

DMillerNCR

Ah - I answered without checking first. Bad.

Entering $(ProjectDir)\ does not bring up any autocompletion. Entering $(ProjectDir)\..\ still brings up the wrong tree relative to the install directory.

In 7.1 I could enter ..\ and it would provide auto completion directories relative to the project. So far nothing works correctly for auto completion in 8.0





Re: Visual C++ General Change in behavior of properties from VC7.1 to VC8

dbc42

This seems to be an unpleasant feature in VC8. When will this be fixed



Re: Visual C++ General Change in behavior of properties from VC7.1 to VC8

crescens2k

This is strange you know. I've done things like ..\ and it was in relation to the project directory.

Have you changed the environment variables somehow That is the only way you can mess up the behaviour of the macros. If all else fails then just do a full path to the include directory.

Just out of curiosity though, what is your additional include directories set to.






Re: Visual C++ General Change in behavior of properties from VC7.1 to VC8

DMillerNCR

The problem is that sometimes it works and sometimes it doesn't. I can't determine a pattern for when it works. Right now, I just tested it and it doesn't work. Three hours from now it might work.

Currently, if I go to edit the include directories, adding a new include and typing "..\" gives me choices in the installation directory - not relative to my project. I can't do a full path to the directory - that defeats the purpose of relative directories and requires all the other developers to have the exact same directory structure - not an option.

If I ignore the unhelpful choices presented and leave the relative directories - they work.

Additional includes set to:

.;..\src\posmgr;..\src\posmgr\actions;"..\dll - Utils";"..\ocx - PosMgr";"..\src\state-machine";"..\src\state-machine\handlers";"..\src\state-machine\content";..\src\util;..\src\xml;"..\common - messages";..\tbcommon





Re: Visual C++ General Change in behavior of properties from VC7.1 to VC8

yellowbillycat

So I've been poking around the forums here for an hour or so looking for a resolution to this relative path auto completion issue.

Has there been a solution that I cannot find

I have the same issue with auto completion in the additional include directories dialog. Always relative to the VS install. I am using a project that was converted from 2003. (And am now wondering what I was thinking when moving to 2005 ).

Auto complete for include directories give me things like

..\..\Common7

when I manually add paths relative to the project such as

..\..\Ogre

It buids fine as one would expect.

Any solutions

Erik