GAB Code Editor v4 Dashboard Form

From GAB Help
Jump to: navigation, search

< Back to main GAB Code Editor v4 Page

This page describes all the new features of the Dashboard Form.

Menu Bar

The form menu bar is only available on Dashboard Form style GAB Forms.

Standard Elements

Save Button - The Save and Save All buttons are used to save the entire script.
Properties
Visible - Sets if the button is shown in the bar.
Show Save All Button - Sets if the button dropdown arrow is shown, with a "Save All" sub-item.
Events
SaveButtonClick - Fired when the main save button is clicked
SaveAllButtonClick - Fired when the save all button is clicked from the dropdown menu.
Export Button - A button with the EXPORT_BLACK icon.
Properties
Visible - Sets if the button is shown in the bar.
Events
ExportClick - Fired when the export button is clicked
Print Button - A button with the PRINT_BLACK icon.
Properties
Visible - Sets if the button is shown in the bar.
Events
PrintClick - Fired when the print button is clicked
Refresh Button - A button with the REFRESH_BLACK icon.
Properties
Visible - Sets if the button is shown in the bar.
Events
RefreshClick - Fired when the refresh button is clicked
Help Button/Menu - Has a set of help and contact options.
Link: About - Shows an About overlay with the scripts name, version number, and build date (set in the Designer)
Link: What's New - Opens the overlay to a change-log type "What's New" tab. Use Gui.[Form]..AddWhatsNew/ClearWhatsNew to manage items.
Link: Suggest Something - Opens the canny suggestion board for your script. Put the ID (Just the last part of the URL) here to allow the user to click the Canny button.
Link: View this program in GSS Help - Opens the help page for the script. If your script doesn't have a help page, leave this blank.
Link: Report a Problem - Opens ServiceWeb to the call-create page. (Future use)
Properties
Visible - Sets if the button is shown in the bar.
Program Description - Sets the description text on the About overlay (Default).
Program Name - The title of the program, shown at the top of the About overlay (Default).
Bug Visible - Shows or hides the "Report a Problem" link (Future use).
Build Date - The date of the current build/release. Should be updated each time a script is released.
Canny ID - The ID (last part of the URL) for the associated Canny board (Ex. "refacing").
Help ID - The Help ID (last part of the URL) for the associated Help page (Ex. "in_v_supply_and_demand" for Supply & Demand).
Program Description International ID - The Translation ID for the Program Description.
Program Name International ID - The Translation ID for the Program Name.
Version - The version number shown on the About overlay. Not strictly required, but useful for determining if a customer is up to date.
Events
HelpButtonClick - Occurs when the help button is clicked. All other links and buttons have hard coded functions.
Share Menu - Contains options for sharing the current screen.
Button: Chat - FOR FUTURE USE, will open a live chat with GSS.
Button: Email - Used to prepare an email to be sent (handled in GAB code).
Button: Image - FOR FUTURE USE, Take a screenshot of the screen, and copy to the clipboard.
Properties
Visible - Sets if the button is shown in the bar.
Show Chat Button - Sets if the Chat button is visible (Future use).
Show Email Button - Sets if the Email button is visible (GAB code should handle this)
Show Image Button - Sets if the Image button is visible (Future use).
Events
ShareButtonClick - Occurs when the share menu button is clicked.
ShareEmailClick - Occurs when the Email menu button is clicked.
ShareChatClick - Occurs when the Chat menu button is clicked.
ShareImageClick - Occurs when the Image menu button is clicked.
Undo System - If your screen is used for data entry, or requires customer input, enable the undo system.
Note - The Undo/Redo states are tracked automatically on all supported control types. To exclude a field from the system, set the "Exclude From Undo" property under "Behavior" to "True".
Note - Use Gui.[Form]..ClearUndo to clear undo states. Optional params allow you to clear Undo or Redo only.
Search Box - Enables search on your form. Automatically saves the last 10 performed searches for quick access.
Event: PerformSearch - Occurs when the user hits enter in the search box, and a search should be performed.

Custom Elements

Bar Buttons

   Gui.[Form]..BarAddButton(Name as String, Caption as String, [SvgImage as v.Enum.Image], [ParentMenu as String], [BeginsGroup as Boolean])
Name - The unique ID of this item.
Caption - The button's caption text (tooltip if SvgImage is set).
SvgImage - The GSS standard SVG Icon to show as the button.
ParentMenu - The Name of the button to make this button's parent. When set, this button is added as a sub-menu below the parent.
BeginsGroup - When true, a separator appears on the bar immediately preceding the button.
   Gui.[Form]..BarRemoveButton(Name as String)
Name - The unique ID of the button specified in BarAddButton.

Bar Combo Boxes

   Gui.[Form]..BarAddComboBox(Name as String, Caption as String, Width as Long, [InitialValue as String], [DisableEditor as Boolean], [BeginsGroup as Boolean])
Name - The unique ID of this item.
Caption - The box's caption text.
Width - The width of the combo box.
InitialValue - The value of the ComboBox at the time of initialization.
DisableEditor - When true, the user is unable to type in the box, and must select an item from the dropdown.
BeginsGroup - When true, a separator appears on the bar immediately preceding the ComboBox.
   Gui.[Form]..BarRemoveComboBox(Name as String)
Name - The unique ID of the ComboBoxspecified in BarAddComboBox.
   Gui.[Form]..BarAddComboBoxItem(ComboBoxName as String, ItemName as String, ItemDisplayValue as Any, [ItemDataValue as Long])

Adds a new item to the ComboBox dropdown.

ComboBoxName - The name of the ComboBox from BarAddComboBox where this item is added.
ItemName - The unique ID of this item.
ItemDisplayValue - The displayed text in the ComboBox.
ItemDataValue - The numberic value associated with this item.
   Gui.[Form]..BarAddComboBoxItems(ComboBoxName as String, "Dictionary", DictionaryName as String)
   Gui.[Form]..BarAddComboBoxItems(ComboBoxName as String, "DataTable", DataTableName as String, KeyColumn as String, ValueColumn as String)
   Gui.[Form]..BarAddComboBoxItems(ComboBoxName as String, "DataView", DataTableName as String, DataViewName as String, KeyColumn as String, ValueColumn as String)

Adds multiple ComboBoxItems at once.

ComboBoxName - The name of the ComboBox from BarAddComboBox where this item is added.
CollectionType - "Dictionary", "DataTable", or "DataView" depending on which collection you're loading from.
DictionaryName - The name of the Dictionary to populate the ComboBox from.
DataTableName - The name of the DataTable to populate the ComboBox from.
DataViewName - The name of the DataView to populate the ComboBox from.
KeyColumn - Which column of the DataTable or DataView to use as the Key.
ValueColumn - Which column of the DataTable or DataView to use as the Value.
   Gui.[Form]..BarRemoveComboBoxItem(ComboBoxName as String, ItemOrdinal as Long)
ComboBoxName - The name of the ComboBox from BarAddComboBox where this item is removed.
ItemOrdinal - The index of the item to remove.

Bar Text Boxes

   Gui.[Form]..BarAddTextBox(Name as String, Caption as String, Width as Long, [EmptyText as String], [BeginsGroup as Boolean])
Name - The unique ID of this item.
Caption - The box's caption text.
Width - The width of the text box.
EmptyText - The prompt text to show when the box is empty.
BeginsGroup - When true, a separator appears on the bar immediately preceding the text box.
   Gui.[Form]..BarRemoveTextBox(Name as String)
Name - The unique ID of the text box specified in BarAddTextBox.