Greets, Napoleon.
> Hello,
> I'm working my way through C++ in Action. And I'm stuck with the error
> message:
>
> C:\Projects\Winnie\Class.cpp
> In method `void Win::ClassMaker::SetIcons(int)':
> 23 C:\Projects\Winnie\Class.cpp
> no matching function for call to `StdIcon::Load (void *&, int &)'
> 43 C:\Projects\Winnie\Icon.h
> candidates are: void StdIcon::Load(HINSTANCE__ *, int)
>
> I have gone through the files Icon.h, Icon.cpp and the functions are all
> there. Icon.h has also been included in Class.cpp. What could be wrong.
> For
> the record I have all the project files in one directory. I have linker
> errors when I split them into differnt directories.
>
> I'll appreciate your help please.
>
> Napoleon.
When you place a file in a different directory, say "icon_class", you have
to update the #include directive correspondingly. For example, if it was
#include "icon.h"
when `icon.h' is in the same directory, then, if you move it to
`icon_class', it would become:
#include "icon_class/icon.h"
This is for the header files. For the CPP files, you have to update the
Dev-C++ project itself, so it's better that you decide on the directory
structure before-hand and stick to it.
Hope this helps.
___________________________________________________________
Abhijit Shylanath
E-mail: mu...@gm... || ibr...@bi...
Web-site: http://mudeth.tripod.com/
|