---
title: "appendOutcomeValue(withType:at:completion:)"
framework: CareKit
role: symbol
role_heading: Instance Method
platforms: [iOS 13.0+, Mac Catalyst 13.0+, watchOS 7.0+]
path: "carekit/ocktaskcontroller/appendoutcomevalue(withtype:at:completion:)"
---

# appendOutcomeValue(withType:at:completion:)

Adds an outcome value to the array of outcomes for an event.

## Declaration

```swift
func appendOutcomeValue(withType underlyingType: OCKOutcomeValueUnderlyingType, at indexPath: IndexPath, completion: ((Result<OCKAnyOutcome, Error>) -> Void)?)
```

## Parameters

- `withType  `: The type of value the outcome is.
- `indexPath  `: The location of the event in the collection view in the task view controller.
- `completion  `: A completion handler the function calls when it is done.

## See Also

### Handling Task Selection

- [eventFor(indexPath:)](carekit/ocktaskcontroller/eventfor(indexpath:).md)
- [initiateDetailsViewController(forIndexPath:)](carekit/ocktaskcontroller/initiatedetailsviewcontroller(forindexpath:).md)
- [initiateDeletionForOutcomeValue(atIndex:eventIndexPath:deletionCompletion:)](carekit/ocktaskcontroller/initiatedeletionforoutcomevalue(atindex:eventindexpath:deletioncompletion:).md)
- [makeOutcomeFor(event:withValues:)](carekit/ocktaskcontroller/makeoutcomefor(event:withvalues:).md)
- [setEvent(atIndexPath:isComplete:completion:)](carekit/ocktaskcontroller/setevent(atindexpath:iscomplete:completion:).md)
