1,file->new->ATL COM AppWizard,命名:VCAtlPlayer
2,insert ATL object
insert->inser Atl Object->control->full control
在CPlayerCtrl构造函数中我们可以看到:
CPlayerCtrl()
{
m_bWindowOnly = TRUE;
}
这个是设置成功的。
同样注释掉,onDraw里面的内容
3,加入ATL Dialog
insert->insert Atl object->Miscellaneous->Dialog
设置PlayerWnd对话框属性,同VC6 Activex控件开发设置:
Style:Child,Border:None,Visible,control,static edge勾上
4,右键CPlayerCtrl->add windows message handle->WM_CREATE->add and edit
5,添加ATL提供给IE的接口
后面的工作同其它一致
OVER