CATPathElement
public CATPathElement( const CATBaseUnknown* iObject = NULL )
Constructs the class from an object.
Parameters:
iObject
the object which will be the first object of the path. Notice that one
CATBaseUnknown.AddRef is done on this object. 作者: liuruixiao205 时间: 2005-8-24 15:08
//call GetRootContainer() to return the root element of the given document
CATFrmEditor * pEditor =CATFrmEditor::GetCurrentEditor();
if ( NULL != pEditor )
{
CATPathElement path = pEditor->GetUIActiveObject();
int j=path.GetSize();
int i=0;
for (i=0;i<j;i++)
{
//CATLine *Line;
CATBaseUnknown * _pActiveObject ;
_pActiveObject=path;
CATISpecObject *_pUIActiveObject;
if ( NULL != _pActiveObject )
{
rc = _pActiveObject->QueryInterface(IID_CATISpecObject, (void**)[$_pUIActiveObject)]
我想这样来得到对象,需要用CATPathElement时,就可以直接用里面的path[size],可是连对象都找不到。作者: liuruixiao205 时间: 2005-8-24 15:10
saeba 试过吗?我试试。我本来用CATIBuild来build一个的,交互没问题,可是一做批处理就出错,作者: saeba 时间: 2005-8-24 15:36
看了你的source有点糊涂了。。。
你是要得到(1)那些点,线的PathElement还是(2)某个UIActivate的PathElement中的元素?
CATPathElement( const CATBaseUnknown* iObject = NULL ) 地说明理由这样的字样:
iObject
the object which will be the first object of the path
因此它只能生成一个以本Object为root的Path,是不符合要求的。
是我搞错了,对不起!
其实acoka这里的source我也有的,很长时间不用。。。给忘了
这里看到了才觉得眼熟,呵呵
Sorry to liuruixiao205