You start with an IFeature object and want to get a more specific object

A call to IFeature::GetSpecificFeature2 is required. If you have the more specific object, then a call to QueryInterface in C++ or an assignment to a IFeature-typed variable allows an application to get back to the IFeature object.

You can use the return value with QueryInterface to determine the object returned.

No interface exists

This method returns Nothing or null.

For some feature types, this method returns Nothing or null because there is no specific object for that type of feature (e.g., features such as extrusions, lofts, fillets, chamfers, etc.). For these types of features, call IFeature::GetDefinition to get their feature data objects.

For other entities selected in the FeatureManager design tree, you must know its interface in advance and cast the return value of ISelectionMgr::GetSelectedObject6 to the correct interface.

For all functions that return objects, always check whether the return value is Nothing or null before you try to use it.

See Also

Availability

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

*Email:

Subject:

Feedback on Help Topics

Page:

GetSpecificFeature2 Method (IFeature)

*Comment:

*

I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.