Re: Wierd Problem-missing .lib files even after successful dll creation
veenuuu@gmail.com wrote:
Thanks for those valuable suggestions.
I have exported the whole class and now the dll is fine.
I can see the .lib files also.
Can you please tell me how to access these functions.The following is
my main prg,is this a correct way?Please suggest.
#include "optest.h"
int main( )
{
int m,n,c;
oper p;
[...]
When i am trying to access the class functions with its instance i am
getting an error like,
error C2065: 'oper' : undeclared identifier
What shall i do?
I guess the error happens on that line and the reason is that you didn't
declare class oper in optest.h, so it is unknown in the code that uses it.
Note that in your original example, you had a class that had a function
called add() and you had a free function called add. Those are two distinct
things that have nothing to do with each other.
Please, just create a DLL with the wizard, using a setup that exports some
things (it then exports a class, a function and a variable) and then create
a simple project that uses them (set the DLL as a dependency in the setup
of the IDE). If you have this running and you can access things, then start
modifying it according to what you need.
Uli