BindingInterface Class Interface

Used in custom object bindings to identify the source and destination objects used in the bind.

Methods
bind

# Example

The following bind method identifies the source object for the bind as a PushButton and the destination object as a Listbox. The #Pragma gives the text that appears in the Object Binding dialog when the programmer establishes the bind in the IDE.

// Part of the bindingInterface interface.
#pragma bindingSpecification PushButton,ListBox, _
"Delete all rows in %2 when %1 is pushed"
BindSource=PushButton(source)
BindTarget=ListBox(dest)
BindSource.addActionNotificationReceiver Self

The #pragma statement defines what will appear in the Bind dialog box when the user binds the two objects. It indicates the source class, the target class, and the text that will appear in the Bind window. %1 will be the name of the source control and %2 will be the name of the target control.

When the objects being bound are passed in to the bind method, they are passed as generic objects. The assignment statements cast them as a PushButton and ListBox, respectively.

# See Also

ActionNotificationReceiver class interface.