Business Exception Steps

Hey, I’m using REFramework for my process and I need to compare some data against an excel sheet and check whether these data are duplicated within the excel or not, if yes, it should throw a business exception, send an email to the client and then go to the next transaction. I used throw, try-catch, throw and try-catch but none of them triggers the bot to move to the next transaction. What is the right way to use business exceptions? I though by just using a throw activity and specifying the type of exception would trigger the bot to move to next transaction.

To throw a business exception, you use the Throw activity with parameter New BusinessRuleException("Exception message"), where “Exception message” is the message you want to display to describe the business exception.

3 Likes

Yes that’s exactly what I did, and by that way it should stop the current transaction and move to next transaction right?

In the REFramework, yes.

I have tried it multiple times, it just throws the exception, sends an email and stops the process with a message saying “ Process finished due to no more transaction data” although I do have more transactions.

@nouf_alhammad - is there more data for the second transaction to process? Can you check your TransactionItem datatable?
You can add a Break Point in Get Transaction Data to debug

Also, are you handling the Business Rule Exception in Catch?

I tried that but didn’t work as intended, now it works but just using a throw activity.

Hi, did you solve your issue?

REFramework is overkill for such a simple process. You should build a process from scratch for this to make it simpler and easier to work with.

I agree reframework is not needed in this particular situation.