---
title: "initiateDeletionForOutcomeValue(atIndex:eventIndexPath:deletionCompletion:)"
framework: CareKit
role: symbol
role_heading: Instance Method
platforms: [iOS 13.0+, Mac Catalyst 13.0+, watchOS 7.0+]
path: "carekit/ocktaskcontroller/initiatedeletionforoutcomevalue(atindex:eventindexpath:deletioncompletion:)"
---

# initiateDeletionForOutcomeValue(atIndex:eventIndexPath:deletionCompletion:)

Returns an alert controller with localized text, to confirm deleting an outcome.

## Declaration

```swift
func initiateDeletionForOutcomeValue(atIndex index: Int, eventIndexPath: IndexPath, deletionCompletion: ((Result<OCKAnyOutcome, Error>) -> Void)?) throws -> UIAlertController
```

## Parameters

- `index  `: The location in an array of outcome values.
- `eventIndexPath  `: The section and row of the event.
- `deletionCompletion  `: A completion handler that is called when the store deletes the outcome.

## See Also

### Handling Task Selection

- [appendOutcomeValue(withType:at:completion:)](carekit/ocktaskcontroller/appendoutcomevalue(withtype:at:completion:).md)
- [eventFor(indexPath:)](carekit/ocktaskcontroller/eventfor(indexpath:).md)
- [initiateDetailsViewController(forIndexPath:)](carekit/ocktaskcontroller/initiatedetailsviewcontroller(forindexpath:).md)
- [makeOutcomeFor(event:withValues:)](carekit/ocktaskcontroller/makeoutcomefor(event:withvalues:).md)
- [setEvent(atIndexPath:isComplete:completion:)](carekit/ocktaskcontroller/setevent(atindexpath:iscomplete:completion:).md)
