Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

ORG-11096

A Toggle Button displays checked/unchecked states as a button

Image Removed

 

Sample OPX to download to try: Toggle Button.opx



Origin 2015 support add an text box named "labtalk Variable to toggle" in the Button Settings dialog.The variable can be pass to script file.

Labtalk Variable
Description
 
state:1 or statebutton will be toggled between states that is pressed-down or not pressed-downImage Added
state:2,state:3,etcbutton has 2/3 states, icon image will use itself by default and another one/two following in the bitmapImage Added

Note:button will be disable if LabTalk variable is not defined or contains missing value

...

  1. Open the Customize Toolbar dialog box (View:Toolbars) and select the Button Groups tab.
  2. Select the User Defined button group from the Groups list.
  3. Select a button in the Buttons group.
  4. Click on the Settings button in the Button group. This opens the Button Settings dialog box.

          Image Removed  Image Added

Examples:

Download Toggle Button.opx and play.

...

1.b Open button settings dialog,Click browse button,browse and select toggle button.ogs as File Name.

1.c Fill StatemyVar:1 in Labtalk Variable to toggle text box.close dialog,drag button to origin workspace.

...

2.b Open button settings dialog,Click browse button,browse and select toggle button_1.ogs as File Name.

2.c Fill Statestate:13 in Labtalk Variable to toggle text box.set section name as Main,close dialog,drag button to origin workspace.

...