<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.10.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Social",
  "identifier" : "/documentation/Social/SLComposeServiceViewController/didSelectCancel()",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Social"
    ],
    "preciseIdentifier" : "c:objc(cs)SLComposeServiceViewController(im)didSelectCancel"
  },
  "title" : "didSelectCancel()"
}
-->

# didSelectCancel()

Sent to the compose view after the cancel animation finishes.

```
func didSelectCancel()
```

## Discussion

By default, this method calls the completeRequestReturningItems: method of the associated <doc://com.apple.documentation/documentation/UIKit/UIViewController/extensionContext> property, passing the appropriate error value in the `items` array and a `nil` expiration.

---

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)