VC使用NTGraph控件时,务必要添加程序对ActiveX的支持,否则程序插入控件会导致程序无法启动。
如果在创建工程时选择了不支持ActiveX,可以在程序CYourApp中添加如下代码:
BOOL CYourApp::InitInstance()
{
AfxEnableControlContainer();
// Standard initialization
// If you are not using these features and wish to reduce the size
// of your final executable, you should remove from the following
// the specific initialization routines you do not need.
.
.
.
}