AudioParam: cancelAndHoldAtTime() method

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since April 2021.

The cancelAndHoldAtTime() method of the AudioParam interface cancels all scheduled future changes to the AudioParam but holds its value at a given time until further changes are made using other methods.

Syntax

js
cancelAndHoldAtTime(cancelTime)

Parameters

cancelTime

A double representing the time (in seconds) after the AudioContext was first created after which all scheduled changes will be cancelled.

Return value

A reference to the AudioParam it was called on.

Specifications

Specification
Web Audio API
# dom-audioparam-cancelandholdattime

Browser compatibility

BCD tables only load in the browser