sharingService(_:didCompleteForItems:error:)
Tells the delegate when the cloud-sharing service completes.
Declaration
optional func sharingService(_ sharingService: NSSharingService, didCompleteForItems items: [Any], error: (any Error)?)Parameters
- sharingService:
The cloud-sharing service that invokes this delegate method.
- items:
The items the service is sharing.
- error:
If the service can’t share the items, an error that provides information about the failure; otherwise, Nil 227m0.
Discussion
The cloud-sharing service invokes this method when the user finishes sharing or dismisses the service’s view controller. If you implement this method, the service calls it instead of the sharingService(_:didFailToShareItems:error:) and sharingService(_:didShareItems:) methods.