---
title: delegate
framework: CareKit
role: symbol
role_heading: Instance Property
platforms: [iOS 13.0+, Mac Catalyst 13.0+, watchOS 7.0+]
path: carekit/ocktaskviewcontroller/delegate
---

# delegate

An object that handles important events inside a view controller.

## Declaration

```swift
weak var delegate: OCKTaskViewControllerDelegate?
```

## Overview

Overview If you set it, the delegate will receive callbacks when important events occur.

## See Also

### Handling Event Changes

- [OCKTaskViewControllerDelegate](carekit/ocktaskviewcontrollerdelegate.md)
- [didSelectTaskView(_:eventIndexPath:)](carekit/ocktaskviewcontroller/didselecttaskview(_:eventindexpath:).md)
