---
title: discardWorkout()
framework: healthkit
role: symbol
role_heading: Instance Method
path: healthkit/hkworkoutbuilder/discardworkout()
---

# discardWorkout()

Stops the collection of data and discards the current results without saving the workout.

## Declaration

```swift
func discardWorkout()
```

## See Also

### Ending the workout

- [endCollection(withEnd:completion:)](healthkit/hkworkoutbuilder/endcollection(withend:completion:).md)
- [endDate](healthkit/hkworkoutbuilder/enddate.md)
- [finishWorkout(completion:)](healthkit/hkworkoutbuilder/finishworkout(completion:).md)
