---
title: HandleChangeSampleRate
framework: audiodriverkit
role: symbol
role_heading: Instance Method
path: audiodriverkit/iouseraudioclockdevice/handlechangesamplerate
---

# HandleChangeSampleRate

Tells the clock device the sample rate is changing.

## Declaration

```occ
virtual kern_return_t HandleChangeSampleRate(double in_sample_rate);
```

## Parameters

- `in_sample_rate`: The sample rate to set, if possible, as a double.

## Return Value

Return Value kIOReturnSuccess on success, or another value if an error occurs. For a list of error codes, see Error Codes.

## Discussion

Discussion The default implementation calls SetSampleRate and returns kIOReturnSuccess. Subclass and override this method to handle changes to the sample rate and return kIOReturnSuccess upon success.
