I know how to use CFrameWnd::Create
to create a frame based application without inserting resources from the resource file, just like below:
#include <afxwin.h>
class MyFrame : public CFrameWnd
{
public:
MyFrame()
{
Create(NULL,_T("Title"));
}
};
class MyApp : public CWinApp
{
public:
BOOL InitInstance()
{
CFrameWnd *Frame = new MyFrame;
m_pMainWnd = Frame;
Frame->ShowWindow(SW_SHOW);
return true;
}
} a_app;
I know I have to create a dialog based application by inserting dialog resource from the resource file. But is it possible to use CDialog::Create
to create a dialog based application without inserting dialog resource from the resource file? (like above)