Share this page

# TCA.doneWithError

Finishes an asynchronous operation with an error.

Note: The execution engine waits for completion notification after asynchronous APIs are called. It waits until TCA.done(result) is called if the execution succeeds, or until TCA.doneWithError(error) is called if the execution fails; the call should be at the end of the execution path of the JavaScript block. If neither are called, the current step fails with “Evaluate JavaScript code timeout” error.

    TCA.doneWithError(error);

## Arguments

error. (any) Any object can be used to stand for the error detail.

## Return value

None

## Example

Copy code

    IOA.read(TC.scriptDir + "mylog.txt").then(function(data){
      TCA.done(data);
    }).catch(function (error) {
      TCA.doneWithError(error);
    });

Tips to improve your search results... VuGen Function Reference Version 26.1 Function Reference 26.1 All View Local Help Center View Online Help Center Version: