B
Bill S.
Hi,
I'm trying to create an unmanaged instance within a managed object. In the
one module, I've constructed an unmanaged class that makes a lot of API
calls. It compiles with no errors. In the other module, when an instance of
the unmanaged class is created, a Link error is encountered. (Unresolved
external symbol ...). If comment out the line of code: uc = new
MyUnmanagedClass(), the app builds with no errors. Can anybody help?
Thanks.
//Unmanaged module ///////////////////////////////////////////
using namespace System::Runtime::InteropServices;
#include "stdafx.h"
#include <windows.h>
class MyUnmanagedClass{
//Windows API Stuff.
};
//Managed module /////////////////////////////////////////////
class Form1{
private:
MyUnmanagedClass *uc;
public:
Form1()
{
//A Link error occurs here.
uc = new MyUnmanagedClass();
}
};
I'm trying to create an unmanaged instance within a managed object. In the
one module, I've constructed an unmanaged class that makes a lot of API
calls. It compiles with no errors. In the other module, when an instance of
the unmanaged class is created, a Link error is encountered. (Unresolved
external symbol ...). If comment out the line of code: uc = new
MyUnmanagedClass(), the app builds with no errors. Can anybody help?
Thanks.
//Unmanaged module ///////////////////////////////////////////
using namespace System::Runtime::InteropServices;
#include "stdafx.h"
#include <windows.h>
class MyUnmanagedClass{
//Windows API Stuff.
};
//Managed module /////////////////////////////////////////////
class Form1{
private:
MyUnmanagedClass *uc;
public:
Form1()
{
//A Link error occurs here.
uc = new MyUnmanagedClass();
}
};