PDA

View Full Version : How can I continue the build on failure and capture the failure information?


kinook
05-12-2004, 11:52 AM
First, select the Continue building radio button on the More tab (http://www.kinook.com/VisBuildPro/Manual/stepfailure.htm) of the Step Properties dialog so that the build will continue if the step fails.

For processing the failure info:

Option #1: Check the Build failure steps option and capture or process the failed step info in steps of the Failure Steps (http://www.kinook.com/VisBuildPro/Manual/failurestepstab.htm) pane (you can specify which failure steps to build on the General tab or leave blank to build all failure steps). The failure step object will be available in the FailedStep object, and the FAILSTEP_OUTPUT system macro will contain the failed step's output.

Option #2: Uncheck the Build failure steps checkbox and capture or process the failed step info in the vbld_StepDone script event (http://www.kinook.com/VisBuildPro/Manual/scriptevents.htm). When a step marked to ignore failure completes, the Step.BuildStatus property will contain the success/failure status of the step, and the LASTSTEP_OUTPUT system macro (http://www.kinook.com/VisBuildPro/Manual/systemmacros.htm) will contain the step's output. In the step's vbld_StepDone script event, call a script function to check the status and append the information for use at the end of the build (for instance, to send in an email message). The attached sample demonstrates this.

Note: The step properties and script event code can be edited for multiple steps at once by multi-selecting the steps and editing the step properties.