Skip to main content

[archive] Toolbar button - enable/disable

  • March 25, 2009
  • 3 replies
  • 0 views

[Migrated content. Thread originally posted on 24 March 2009]

Maybe I'm slightly dense today, But I'm trying to figure out the correct syntax to enable/disable a button on the toolbar. Also note that all I have is the handle to the toolbar.

Something like:

MODIFY TOOLBAR-HANDLE, MY-PUSHBUTTON, ENABLED = 0 OR
MODIFY TOOLBAR-HANDLE::MY-PUSHBUTTON, ENABLED = 0

Anyone know the correct syntax? Or do I need a handle directly to my pushbutton to get the job done?

3 replies

[Migrated content. Thread originally posted on 24 March 2009]

Maybe I'm slightly dense today, But I'm trying to figure out the correct syntax to enable/disable a button on the toolbar. Also note that all I have is the handle to the toolbar.

Something like:

MODIFY TOOLBAR-HANDLE, MY-PUSHBUTTON, ENABLED = 0 OR
MODIFY TOOLBAR-HANDLE::MY-PUSHBUTTON, ENABLED = 0

Anyone know the correct syntax? Or do I need a handle directly to my pushbutton to get the job done?
Looks like you do need the handle for the push-button to be able to edit the properties of it, it's not good enough to have just the handle of the toolbar. also note the handle has to be of type push-button to have access to all the properties.

[Migrated content. Thread originally posted on 24 March 2009]

Maybe I'm slightly dense today, But I'm trying to figure out the correct syntax to enable/disable a button on the toolbar. Also note that all I have is the handle to the toolbar.

Something like:

MODIFY TOOLBAR-HANDLE, MY-PUSHBUTTON, ENABLED = 0 OR
MODIFY TOOLBAR-HANDLE::MY-PUSHBUTTON, ENABLED = 0

Anyone know the correct syntax? Or do I need a handle directly to my pushbutton to get the job done?
How about setting an enable variable for the control you want to enable/disable, then set the var to 0 and either display screen or display toolbar-handle. that might work.

[Migrated content. Thread originally posted on 24 March 2009]

Maybe I'm slightly dense today, But I'm trying to figure out the correct syntax to enable/disable a button on the toolbar. Also note that all I have is the handle to the toolbar.

Something like:

MODIFY TOOLBAR-HANDLE, MY-PUSHBUTTON, ENABLED = 0 OR
MODIFY TOOLBAR-HANDLE::MY-PUSHBUTTON, ENABLED = 0

Anyone know the correct syntax? Or do I need a handle directly to my pushbutton to get the job done?
how about this example