Reply

How to select a edge

[ Edited ]

 

Hi, Jason, Could you help me to anylze the codes?

m_pSEMouse->ClearLocateFilter();

m_pSEMouse->AddToLocateFilter(SolidEdgeConstants::seLocateEdge);

HRESULT CLocateCommand::MouseClick(short sButton,

                                   short sShift,

                                   double dX,

                                   double dY,

                                   double dZ,

                                   LPDISPATCH pWindowDispatch,

                                   long lKeyPointType,

                                   LPDISPATCH pGraphicDispatch)

{

SolidEdgeGeometry::EdgePtr pEdge;

    pEdge=(SolidEdgeGeometry::EdgePtr)(IDispatch*)pGraphicDispatch;

}

pEdge is null.

 

Posted by: assassin 007
Post date: 5/10/2009 10:38:13 PM

4 REPLIES

RE: How to select a edge

[ Edited ]

Hi, anybody can help me?

 

Posted by: assassin 007
Post date: 5/11/2009 1:09:16 AM

RE: How to select a edge

[ Edited ]

Dear Jason, could you hlep me? Or give me a sample? Thanks!

 

Posted by: assassin 007
Post date: 5/18/2009 3:59:30 AM

RE: How to select a edge

[ Edited ]

Dear All, I've solved the issue.

SolidEdgeFramework::ReferencePtr pRef;

hr=pGraphicDispatch->QueryInterface(&pRef);

 

IDispatchPtr pIDis;

 

pIDis=pRef->GetObjectA();

 

hr=pIDis->QueryInterface(&pEdge);

 

hr's value is S_OK

 

Posted by: assassin 007
Post date: 5/18/2009 5:09:04 AM

RE: How to select a edge

[ Edited ]

I get the idea from x:\\SE\\Custom\\MouseObject.

I can get vertex and face by the same way.

 

Posted by: assassin 007
Post date: 5/18/2009 5:10:30 AM