Setting Transaction Status in Global Exception Handler

Hey all,
I am working with the queue and trying to set the status as failed whenever the automation fails anywhere in the main.xaml.

Inside of GlobalExceptionHandler, the errorInfo variables have these information -

So I put errorInfo.Variables[“TransactionItem”] inside of Set transaction status activity under TransactionItem input. However, I am getting an error message saying that it cannot convert type object to uipath.core.QueueItem even though errorInfo.Variables[“TransactionItem”].GetType() returns uipath.core.QueueItem

image

Am I missing something?
Is there a better way to do this by adding more arguments into the global exception handler workflow?

1 Like

@jkwon

Are you using REFramework template ? If yes then set the Transaction Item status in SetTransactionStatus workflow.

Hey @jkwon

Could you please show how are adding into the error info as well as how are passing it to set transaction?

Thanks
#nK