AnnGetName method (Main Control)

Visual Basic example
Visual C++ 4.0 example

Syntax BSTR AnnGetName(OLE_HANDLE hObject, BOOL * bShowName);

Overview:  Refer to Implementing Annotations.

Remarks

(Document/Medical only) Gets the name of the specified object.

When you create an object in the automation mode, the value for bShowName is taken from the automation object. The name of the object is also taken from the automation object, specifically from the ANNAUTOTEXT_ITEM_DEFAULTNAME item. This is just like the annotation text, which is by default "AaBbYyZz" and is taken from ANNAUTOTEXT_ITEM_DEFAULTTEXT item.

The default name is "", which means that the objects will not show a name when you create them. To set a default name, call AnnSetAutoText method with iItem set to ANNAUTOTEXT_ITEM_DEFAULTNAME, and pszText set to your desired default string. For example:

LEAD1.AnnSetAutoText ANNAUTOTEXT_ITEM_DEFAULTNAME, "Default_name"

See Also

Elements:  AnnSetName method

Topics:  Annotations (Document/Medical only): Object Manipulation