DisplayButtons (enable appropriate toolbar buttons:ToolbarReltreeClass)


Top  Previous  Next

 

DisplayButtons, VIRTUAL

The DisplayButtons method enables and disables the appropriate toolbar buttons for the ToolbarReltreeClass object based on the values of the HelpButton, InsertButton, ChangeButton, DeleteButton, and SelectButton properties.

Implementation:     The TakeToolbar method calls the DisplayButtons method.

Example:

CODE

Toolbar.Init                                   !initialize Toolbar object

 ToolBar.AddTarget( ToolBarForm, -1 )          !register an Update Form target

 Toolbar.AddTarget( REL1::Toolbar, ?RelTree )  !register a RelTree target

 ToolBar.SetTarget( ?RelTree )                 !calls DisplayButtons via TakeToolbar

!program code

 

MyToolbarReltreeClass.DisplayButtons PROCEDURE  !a derived class virtual

CODE

DISABLE(Toolbar:History)                      !disable toolbar ditto button

ENABLE(Toolbar:Locate)                        !enable locator button

PARENT.DisplayButtons                         !call base class DisplayButtons

!your custom code here

 

See Also:     HelpButton, InsertButton, ChangeButton, DeleteButton, SelectButton, TakeToolbar