BBjGrid::setEnabled

Description

This method sets whether the BBjGrid is enabled.

Syntax

Return Value

Method

void

setEnabled(boolean enabled)

Parameters

Variable

Description

enabled

Specifies whether to enable/disable the BBjGrid

0 = Disabled.

1 = Enabled; this is the default.

Return Value

None.

Remarks

In BBj 15.0 and higher, legacy mode and enhanced mode are available. In both  modes, the selections can still be changed programmatically while the grid is disabled.

In legacy mode, once the grid has been disabled (enabled = 0), the highlighting and selections will no longer appear. When the grid is enabled (enabled = 1), any previous highlighting and selection will reappear.

In enhanced mode, once the grid has been disabled (enabled = 0), the highlighting and selections will remain, but no further user inputs will change the highlighting. When the grid is enabled (enabled = 1), any previous highlighting and selections can be changed.

Example

declare BBjSysGui sysgui!
declare BBjTopLevelWindow win!
declare BBjStandardGrid grid!

sysgui!=BBjAPI().openSysGui("X0")
win!=sysgui!.addWindow(0,0,800,600,"GridTest")
grid!=win!.addGrid(win!.getAvailableControlID(),10,10,335,580,$8040$,6,4)

grid!.setSelectedCell(3,2)
grid!.setEnabled(0)
process_events

See Also

BBjAPI

BBjControl

BBjControl::isEnabled

BBjGrid::isEnabled

BBjWindow

See the BBj Object Diagram for an illustration of the relationship between BBj Objects.