wf_bottomBar_reload()

Updates the buttons of the bottomBar of the wizard framework.

Synopsis

dyn_string wf_bottomBar_reload([string sReferenceName = ""], [bool bInit = false);

Parameters

Parameter Description
sReferenceName Reference name of the bottom bar reference. By using the parameter you can refer to the bottomBar in a script. When the function "wf_bottonBar_reload()" is used in the wizard framework, the sReferenceName parameter can be left empty.
bInit Set the parameter to TRUE when you load the bottomBar the first time.

Return value

Returns the buttons of the bottom bar, which are visible after the reload.

Errors

Missing or wrong arguments

Description

Updates the buttons of the bottomBar of the wizard framework. The function calls the isChanged function of the wizard frame work and if changes were made, the buttons of the bottom bar are enabled or disabled.

EXAMPLE

  1. Create in the graphic editor GEDI a panel with a text field and a button and add the following code to the button:

main()
{
  TEXT_FIELD1.text = getCurrentTime();
  // ... do something to change the panel content ...
  wf_bottomBar_reload("", TRUE); // reload the bottom bar
}

Thus, the current time is shown in the text field and the bottonBar is reloaded.

Figure: Panel that is loaded in the wizard

  1. Open the wizard framework and create a wizard. Add the panel (see above) to the wizard. Activate the check box "Show Save button inbottom bar?" Under "Save function" add the following code (see figure "New wizard" further below):

#uses "wizardFramework.ctl"
//Function for saving
int main()
{
  //Do something to save your panel content ...
  shape var = getShape($sWf_shapePath+"TEXT_FIELD1");
  var.text = "Saved"; /* When you click the "Save" button, the
  text "Saved" 
  is shown in the text field */
  wf_bottomBar_reload(); //Reload the bottom bar
  return 0;
}

The code shows the text "Saved" when you click the "Save" button of the bottomBar.

  1. Under "Change Function" add the following code:

#uses "wizardFramework.ctl"
bool main()
{
  shape var =getShape($sWf_shapePath+"TEXT_FIELD1");
  return (var.text != "");
}

The code checks the changes of the text field.

  1. Click the "Save" button - see figure below:

Figure: New Wizard

  1. Open your wizard via System Management panel/Wizards tab and click on the "Text" button. The current time is shown in the text field. Click on the "Text" button again and then on "Save". The text "Saved2 is shown.

Figure: New wizard

Assignment

Wizard Framework

Availability

UI