VBPromotedAttribute Statement

The VBPromotedAttribute statement describes the implementation and interface of an attribute that is promoted to the interface of a composite part. The VBAttribute statement describes only the interface of a promoted attribute. In addition to the information specified for a VBAttribute statement, the VBPromotedAttribute statement identifies the source of the promoted attribute. Use this statement to describe promoted attributes.

{ //VBPromotedAttribute: name, description?, type, getSignature?, setSignature?, eventId?, subpartName, subpartFeatureName, featureFlag*, displayName? }

name
Attribute name to be used in visual composition.

description
Optional feature description.

( "text description" | (resourceId, resourceDll) )

resourceId
Optional resource number of the descriptive text. If you specify a resource ID, you must also specify the resource DLL name.

resourceDll
Optional resource DLL name containing the descriptive text. You must specify the DLL name if you specify a resource ID. Do not include the .dll extension.

type
Attribute data type. This must be compatible with the type used for get and set member functions.

getSignature
Optional signature of a C++ public member function that returns the attribute value. The member function must either have no parameters, or all parameters must have values supplied. Parameters can be supplied with either default values, such as int i=1, or hard-coded values, such as =1.

setSignature
Optional signature of a C++ public member function that changes the attribute value. The member function must either have one parameter, or all parameters after the first must have values supplied. Parameters can be supplied with either default or hard-coded values.

eventId
Optional C++ public notification ID for visual and nonvisual parts. If specified, the ID is sent on attribute-to-attribute connections whenever the attribute value changes.

subpartName
The name of the embedded part from which the attribute is promoted.

subpartFeatureName
The name of the attribute that is promoted from the the embedded part.

featureFlag
Optional feature flag.

( connect | noconnect | setting | nosetting | preferred | noWin | noOS2 | noAIX )

connect
Allows connections to the attribute. If neither connect nor noconnect is specified, connect is assumed.

noconnect
Prevents connections to the attribute.

setting
Allows the attribute to appear in the part property sheet. If neither setting nor nosetting is specified, setting is assumed if the attribute has a set member function.

nosetting
Prevents the attribute from appearing in the part property sheet.

preferred
Specifies that the feature is preferred for the part. Preferred features appear in the part connection list.

noWin
Excludes the feature on Windows.

noOS2
Excludes the feature on OS/2.

noAIX
Excludes the feature on AIX.

displayName
Optional display name for the attribute. The display name is used instead of the attribute name in the part property sheet.

( "descriptive name" | (resourceId, resourceDll) )

resourceId
Optional resource number of the descriptive name. If you specify a resource ID, you must also specify the resource DLL name.

resourceDll
Optional resource DLL name containing the descriptive name. You must specify the DLL name if you specify a resource ID. Do not include the .dll extension.


Related procedures
Defining the Part Interface Using Part Information Statements

Related references
Visual Part Information Statements
Nonvisual Part Information Statements
Part Information Statement Descriptions
Part Information Statement Examples