Why not exported base class' member functions in DLL?

A

Allen

I create a DLL project in VC6, exported some classes.

class __descspec(export) CByteBuffer {
public:
INT8* GetCurrAddr(void);
};

class __descspec(export) CReadByteBuffer {
void Wrap(CHAR *pBuffer, INT32 nLength);
};

And write a demo

#include "ByteBuffer.h"
#pragma comment(lib, "bytebuffer.lib");

int main()
{
CReadByteBuffer readByteBuffer;
readByteBuffer.Wrap(buffer, 1024);
INT8 *pAddr = readByteBuffer.GetCurrAddr();
}

Using method in CReadByteBuffer is ok, but GetCurrAddr is unresolved.
Why? Please help me. Thank you.
 
A

Allen

I create a DLL project in VC6, exported some classes.

class __descspec(export) CByteBuffer {
public:
INT8* GetCurrAddr(void);

};

class __descspec(export) CReadByteBuffer {
void Wrap(CHAR *pBuffer, INT32 nLength);

};

And write a demo

#include "ByteBuffer.h"
#pragma comment(lib, "bytebuffer.lib");

int main()
{
CReadByteBuffer readByteBuffer;
readByteBuffer.Wrap(buffer, 1024);
INT8 *pAddr = readByteBuffer.GetCurrAddr();

}

Using method in CReadByteBuffer is ok, but GetCurrAddr is unresolved.
Why? Please help me. Thank you.

I am sorry.
I do implement GetCurrAddr method in ByteBuffer.cpp.
It is mistaked to overwrite by version control.
So stupid I am...

Regards,
Allen Chen
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,817
Latest member
DicWeils

Latest Threads

Top