VLButtonBar Reference

Method Add

See Also See Also Applies To Applies To

Adds a new button to buttons collection of a CGroup object.

 

Syntax

object.Add (ByVal sCaption As String, ByVal aPicture As StdPicture, Optional ByVal sTooltip As String, Optional ByVal sPrompt As String, Optional ByVal sKey As String)

 

The Add method syntax has these parts:

Part Description
object An expression evaluating to an object of CButtons type.
sCaption A caption text which appears for this button in VLButtonBar.
aPicture An expression evaluating to an object of type StdPicture.
sTooltip Optional. A string expression specifing the tooltip corresponding to the new button.
sPrompt Optional. A string expression specifing the help to be shown in the status bar for this button.
sKey Optional. A string expression which uniquely identifies this button in the collection.

 

Remarks

On successful addition of the button, method returns the newly added CButton object. Also, the control will notify button addition by triggering ButtonAdded event.

 

Note : Programming environments, e.g. PowerBuilder, that do not support StdPicture object, can use Add2 to add a button using picture files as source of picture for the button.