Handle Key Not FoundException

When a cloned control is used in an automation and the key specified for the object is not found at runtime, the system issues an exception error. This will halt automation logic flow unless the exception is handled in some way. To handle these types of exceptions, you can add an event to the control's connection block that can be used to specify downstream logic (rather than halt execution with an exception).

Right-click on the object and select the Handle KeyNotFoundException option.

After you choose this option, a new output event, KeyNotFoundException, is added to the connection block as shown in this example:

You can connect this output event to downstream logic which will execute when the specified key for the object is not found at runtime. For example, connect this event to the DiagnosticLog component to write a message to the Studio log to help you debug the solution.

To remove this event from the connection block, right-click on the block and select the Do not handle KeyNotFoundException option as shown in this example:

 


Privacy | Trademarks | Terms of Use | Feedback

Updated: 18 June 2020

© 2016 - 2020 Pegasystems Inc.  Cambridge, MA All rights reserved.

 

OpenSpan data classification label