when i throw business rule exception and i want to stop the bot and send email to business that files are not available
how can do this in try catch kindly let me know
when i throw business rule exception and i want to stop the bot and send email to business that files are not available
how can do this in try catch kindly let me know
You can put Send Mail at the Catches
Use Throw
activity to throw Business rule exception in try
block.
In catch
block add your logic to send email to business.
That’s it.
Sample:
Thanks,
Ashok
Hi @T_Y_Raju ,
Check Below Workflow, hope its helps you
Try block:
Catch Block:
Regards,
Vinit Mhatre
Hi @T_Y_Raju
In the Try Block, use File Exists activity and give the file path and store the output in a variable. The output is of DataType System.Boolean say isFileExists
. Use an If activity and give the below condition:
If
isFileExists
Then
\\ Do the required process
Else
Throw -> New BusinessRuleException("Files are not available")
End If
In the Catch Block, use Send Outlook Mail message and give the required details about the exception.
Regards