Hide Table of Contents
GetAttachedEntityTypes Method (IAnnotation)

Gets the object types associated with this annotation.

.NET Syntax

Visual Basic (Declaration) 
Function GetAttachedEntityTypes() As Object
Visual Basic (Usage) 
Dim instance As IAnnotation
Dim value As Object
 
value = instance.GetAttachedEntityTypes()
C# 
object GetAttachedEntityTypes()
C++/CLI 
Object^ GetAttachedEntityTypes(); 

Return Value

Array of longs or integers (see Long vs. Integer) that indicate the attached entity types as defined in swSelectType_e

Example

Remarks

This method supports all annotation types. Use IAnnotation::GetType to determine the annotation type.

This method returns an array of longs or integers indicating object types. The list of object types corresponds with the list of objects returned by IAnnotation::GetAttachedEntities2.

You can associate annotations with additional items not listed in swSelectType_e. If this annotation is attached to one or more entities not listed, then SolidWorks returns a corresponding swSelNOTHING value in one of the array positions.  IAnnotation::GetAttachedEntities2 indicates the unsupported entity by returning a null value in a specific array position. COM applications that call IAnnotation::GetAttachedEntityCount2 include the null value in the total number of associated entities.

Likewise, if an annotation is disassociated from its geometry (dangling), then SolidWorks returns a corresponding null in one of the array positions and IAnnotation::GetAttachedEntityTypes and IAnnotation::IGetAttachedEntityTypes return a swSelNOTHING value for the dangling item.

COM applications must call IAnnotation::GetAttachedEntityCount2 before calling this method. Annotation::GetAttachedEntityCount2 determines the necessary array size in your call to IAnnotation::IGetAttachedEntityTypes and creates the list of attached entities.

NOTE: If this annotation is not associated with any geometry (for example, a note without a leader line), then SolidWorks returns an empty array.

 

See Also

Availability

SolidWorks 99, datecode 1999207



Provide feedback on this topic

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:   GetAttachedEntityTypes Method (IAnnotation)
*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

Print Topic

Select the scope of content to print:

x

We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again
x

Web Help Content Version: API Help (English only) 2012 SP05

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.