I have been trying to handle the exceptions in my project.
So i am just pasting here small piece of my project.
Suppose the sap.exe file is not present in the location or in the code i will give some wrong path then also it should handle the exception.
The piece of code:
path of exe is :
“C:\Program Files (x86)\SAP\FrontEnd\SAPgui\saplogon.exe1”
buddy are you using this within global exception handler scope, @Seem
if so take the try catch block out from that scope and use it as it is
buddy @Seem
I went through the link ,
I have my main project and i also added the GEH.
but from my main.xaml i am not able to enter in to GEH.
Also once i enter in to the handler.xaml , i want to terminate the main.xaml.
I found the cause of your error message.
You should remove Terminate Workflow from the catch block. It will work fine.
The purpose of try catch block is to catch any errors and end the workflow smoothly.
You shouldn’t be using terminate workflow here.
I have removed the “terminate workflow”.
Actually my process is too big.
I have just pasted a part of it. Well i just want to stop the process where i get the bugs. So how shall i stop the process(which have many sequences)
1st- You can define an out_Error argument in the beginning of each flow, assign it to false. If there is some error, you can catch it in try catch block, set out_Error argument to True in the catch block.
And after this sequence, you can check condition in the parent flowchart that if out_Error argument is False, proceed to the next step, otherwise, send an error mail notification. (You can create this send error mail notification workflow and reuse it in subsequent checks).
2nd- You can use Try catch in the child workflow and in case of any errors, you can use a throw activity with the exception message so that it gets caught in the parent workflow. Inside catch block of parent workflow, you can use Send email (with exception.Message in Body) to notify the concerned people.