Showing results for 
Search instead for 
Do you mean 
Reply
Solved! Go to solution

Error in casting TaggedObject as extract face feature

Hello everyone,

 

I am trying to cast a taggedobject as a extract feature. When I use journaling

 

NXOpen::Features::ExtractFace *extractFace1(dynamic_cast<NXOpen::Features::ExtractFace *>(workPart->Features()->FindObject("EXTRACT_BODY(3)")));

 

This line works.

 

However,

 

std::vector<NXOpen::TaggedObject*> selectedObjects = selection0->GetSelectedObjects();

extractFace1 = dynamic_cast<NXOpen::Features::ExtractFace *>(selectedObjects[0]);

 

returns a Null pointer. Any suggestions?

 

thanks!

1 REPLY
Solution
Solution
Accepted by topic author Erhan
‎04-27-2016 01:01 AM

Re: Error in casting TaggedObject as extract face feature

Try hovering the cursor for a few seconds before making the selection, to be sure you are selecting the extracted face, and not some other geometry - for example, the original face from which it was extracted.