TOleContainer控制word的问题
用BCB做一个Activex控件通过web控制word操作如下,
m_VclCtl->OleContainer->DestroyObject();
//打开Word文档
m_VclCtl->OleContainer->CreateObjectFromFile("c:\\123.doc",false);
m_VclCtl->OleContainer->DoVerb(ovPrimary);
m_VclCtl->OleContainer->OleObject.OlePropertySet("ShowRevisions",false);
在web上运行到第一四句时出现“EaccessViolation”错误,但将此控件(TOleContainer)新建立的工程中又能正常运行,在Activex中OleFunction,OlePropertySet等方法也不能使用。哪位高手给予指点迷津。