Is there some "OnAbort" event or similar that I can use in Ranorex?
Specifically I'm trying to call a method once a user manually aborts the execution (for example by pressing pause, closing the cmd etc.), usually the report recognizes this by stating "The test run has been aborted by the user."
I know about TearDown (but I only want to trigger it on a user abort specifically) and ThreadAbortException but I'd rather not have a try catch block all over my code module.
I had asked a similar question on Ranorex forum as I wanted to have something like an "OnFail" event listener but the official support staff from Ranorex replied that they do not have any such thing yet. The advised to implement it using the Testsuite class to check if the previous test failed/passed etc. But there is nothing yet that can give the status of the execution being stopped manually.
They too suggested using try-catch blocks
You can find the discussion here