i have to classes, WINDOW and BUTTON. they are both to be exported from the dll. also, both of these classes inherit from a class called WNDSKELETON.
when i compiled it gave me an error like this
Code:
warning C4275: non dll-interface class 'WNDSKELETON' used as base for dll-interface class 'CHILD'
i went on the msdn to look up the warning, and from what i understand, i have to export the WNDSKELETON class as well in order to avoid this warning. if i dont do it also get this error in my client:
when i use the function through one of the classes (WINDOW or BUTTON).
what if i dont want the user to be able to use WNDSKELETON directly?
should i just not use inheritance?
thanks in advance!
ok i uploaded the project with all the classes to be exported..thanks to anybody who helps me..also i found out that for some reason, nothing happens when i try to create my window..
thanks again
Make all constructors of the base class protected. This will make it impossible to directly create an object of the base class because the constructor cannot be accessed. The derived classes still can call the constructor, so you can create objects of this classes.
All the buzzt CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.