---
title: "setPeriodicDelay(_:interval:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nsbuttoncell/setperiodicdelay(_:interval:)"
---

# setPeriodicDelay(_:interval:)

Sets the message delay and interval for the button.

## Declaration

```swift
func setPeriodicDelay(_ delay: Float, interval: Float)
```

## Parameters

- `delay`: The amount of time (in seconds) that a continuous button will pause before starting to periodically send action messages to the target object. The maximum value is 60.0 seconds; if a larger value is supplied, it’s ignored, and 60.0 seconds is used.
- `interval`: The amount of time (in seconds) between each action message. The maximum value is 60.0 seconds; if a larger value is supplied, it’s ignored, and 60.0 seconds is used.

## Discussion

Discussion These values are used if the button is configured (by a isContinuous message) to continuously send the action message to the target object while tracking the mouse.

## See Also

### Related Documentation

- [isContinuous](appkit/nscell/iscontinuous.md)

### Managing the Repeat Interval

- [getPeriodicDelay(_:interval:)](appkit/nsbuttoncell/getperiodicdelay(_:interval:).md)
