AfterAction event of RunActionList

Hi everybody,

 

In the AfterAction event of some actions of interest I write the ActionResult out to a database for nightly build reports.

For most actions this works perfectly well, except for RunActionList. Here, the AfterAction event is called while the ActionList is still running, and it always reports success.

Is there any way I can pick up failure of an ActionList (meaning an action inside the list failed) in the AfterAction event?

I'm using FinalBuilder 5.5.0.707

Rgds

Richard

Hi Richard

This is an unfortunate side effect of how action lists work… basically the actionlist’s first runnable action is pushed onto a stack and thus becomes the next action to execute… the side effect is that the run actionlist action actually completes before the actionlist starts.

The work around to this is to wrap the Run ActionList action inside a Try Catch block (right click on it and select the Refactoring menu). If the Run ActionList action fails the Catch block will be executed.

HTH.

Hi Vincent,

Thanks for the information.That solves the biggest part of my problem.

Now, to make it perfect: Is there an easy way to get the actionId of the action that failed from within the catch block?

Rgds

Richard