Salesforce

How Do I Disable Magic xpa Handling for Internal Events? (Magic xpa 4.x)

« Go Back

Information

 
Created BySalesforce Service User
Approval Process StatusPublished
Objective
Description

How Do I Disable Magic xpa Handling for Internal Events? (Magic xpa 4.x)

You can disable Magic xpa handling of Internal events by setting the Propagate property to No. In this example, the user can press Escape or click on the and the task will never close, because the Exit event is effectively blocked. (Fortunately, when testing in the Studio, you can always use the Debug->Stop option to get out of situations like this!).

What isn’t so obvious is that the event will also be blocked if it is used as a Trigger to a User event. This task works just as the other one does: it totally blocks the user from exiting.

If you want to block an event, but also allow it to function under certain conditions, then you can use an Expression for the Propagate property. This is explained in the next example.

Using Conditional Propagate

You can also use an Expression with the Propagate property. Here, we trap the Exit event and give the user an “Are you sure?” message. If the user answers Yes, we update the variable “v.End immediately” to ‘TRUE’LOG. “v.End immediately” is used in the Propagate property, so if the user answers Yes then the Exit event is passed on to Magic xpa, and the task ends.

See also

The Online and Rich Client Samples projects (program EH04 and REH04)

Reference
Attachment 
Attachment