Is there any way to use IMPLEMENT_DYNCREATE with a template class? If not, why not? Is there another solution to this?
Example:
template<typename T>
class A : public B{
public:
A(){ printf("A constuctor "); }
void fn( ){ T* a = new T(); }
};
IMPLEMENT_DYNCREATE(A<CObject>, B);
OK I’ve taken a quick look at the macros and thrown together a completely un tested macro that may work.
Then you can call:
Give it a try, as i say, it may work 😀