Why VC++ .NET 2005 adds a function to a class in a different cpp file?
-
It looks odd to me that VC++ .NET 2005 adds a new function to a different cpp file. I have a folder (named as Dialogs) which stores a bunch of header and cpp files of dialogs in a project (MyApp) folder. When I right click mouse in Class View to add a new function to MyDialog class whose header and cpp files are in Dialogs folder within MyApp folder and click OK, Visual Studio automatically adds the definition of the function to the correct header file, however, it adds the function implentation codes to a new cpp file right in the MyApp folder instead of MyDialog with the same name of the class. In order to have VS correctly place the codes to the cpp file under Dialogs folder, I have to specified the location of cpp file in the Add-member-function-wizard. This means that every time I want to add a function to a class whose cpp file in NOT directly under the default project folder (MyApp in this case), I have to explicitly specify location of its cpp file . This is annoying and is NOT the behavior of VS 6.0. Anyone knows a way to fix this or this is the way VS .NET 2005 is?