<!--
{
  "availability" : [
    "macCatalyst: 14.0.0 -",
    "macOS: 10.5.0 - 10.5.0"
  ],
  "documentType" : "symbol",
  "framework" : "Automator",
  "identifier" : "/documentation/Automator/AMAction/didFinishRunningWithError:",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Automator"
    ],
    "preciseIdentifier" : "c:objc(cs)AMAction(im)didFinishRunningWithError:"
  },
  "title" : "didFinishRunningWithError:"
}
-->

# didFinishRunningWithError:

Sent by the action to itself when it has finished running asynchronously.

```
- (void) didFinishRunningWithError:(NSDictionary<NSString *,id> *) errorInfo;
```

## Parameters

`errorInfo`

If an error occurred during asynchronous running of the action, upon return contains an instance of `NSError` that describes the problem.

## Discussion

An action that overrides [`runAsynchronously(withInput:)`](/documentation/Automator/AMAction/runAsynchronously(withInput:)) should invoke `didFinishRunningWithError:` on completion, so that Automator can resume running the workflow that the action is part of.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)