Adding the Show dialog event action
Use the Show dialog event action to add a modal dialog window that is based on a previously created scene to your visual dashboard.
Before you begin
About this task
Procedure
- In the editor window, select the object to which you want to add the action.
- Double-click the event that you want to trigger the action
from the Events view. The [objectname] Behavior window opens.
- Click the Add button.
- Select Show Dialog in
the actions tree and click Next. Note: To quickly find the required event action, type the name of the action in the filter text field.
- In the Add New Action window, specify the action parameters.
- If you want to open a scene from another visual project,
select the Another visual project check box
and specify a visual project.
- Select the name of the scene that you want to add to the dialog window from the Dialog scene list.
- If you have local parameters in the scene that you want to add from the current visual dashboard, you can modify their initial values for the destination scene when event occurs in the Set values for the existing local parameters list.
- If you want to use a scene from the current project, perform
the following steps:
- Make sure that the Another Visual Project check box is clear.
- Select the name of the scene that you want to add to the dialog window from the Dialog scene list.
- If you have local parameters in the scene that you want to add from the current visual dashboard, you can modify their initial values for the destination scene when event occurs in the Set values for the existing local parameters list.
- In the Title field, specify a title
that you want to add to the dialog. Note: The Title field value equals the Title parameter value of the scene that you use in the dialog.
- In the Dialog Location area, specify
the location of the dialog window. The available options are:
- Center location to set the center of the scene as the location of the dialog.
- Custom location to specify the exact coordinates for the dialog window.
- Click Next. The next page for specifying Show dialog action parameters opens.
- Select the Use Close Dialog action result check box to use the parameter that is got in the Close dialog action.
- If you did not previously specify a parameter for storing
the result value of the event action, select either Global
parameters or Local parameters from
the Result parameter list and click the Add
New Parameter button. The Insert Parameter window
opens. In this window, specify a parameter and click Finish.
The Insert Parameter window closes and control
returns to the Add New Action window. Note: You can add the parameters of the following types:
Boolean
,Integer
,Double
,Text
, andLiteral
. Use the added parameter to specify conditions for the event actions execution. For example, if you use a Boolean parameter in the DialogClose event you can create two different actions that are run depending on theTrue
orFalse
returned value. - Specify the actions that you want to run when the dialog window closes. For the list of available actions, see the Setting up event action navigation topic.
- Click the Add button. The Add
New Action window opens. Specify the parameters for the
selected action, and add it. Note: The local parameters that are specified for the dialog scene are available in the Event Parameters category of the Expression Designer. If you have two parameters with the same name but with different values in the main and dialog scenes, the value that is specified for the dialog scene has higher priority and is used as the dialog scene parameter.
- In the Actions list, you can modify parameters for the added actions.
- Select the parameter that you want to use from the Result
parameter lists and click OK.
The Add New Action window closes.
- Click Finish. The Show dialog event action is added. The Add New Action window closes.
- From the [objectname] Behavior window, click Apply to apply all actions that were added for the event. Click OK to close the [objectname] Behavior window.