---
title: "init(scope:element:dictionary:)"
framework: avfaudio
role: symbol
role_heading: Initializer
path: "avfaudio/avaupresetevent/init(scope:element:dictionary:)"
---

# init(scope:element:dictionary:)

Creates an event with the scope, element, and dictionary for the preset.

## Declaration

```swift
init(scope: UInt32, element: UInt32, dictionary presetDictionary: [AnyHashable : Any])
```

## Parameters

- `scope`: The audio unit scope.
- `element`: The element index in the scope.
- `presetDictionary`: The dictionary that contains the preset.

## Discussion

Discussion The system copies the dictionary you specify and isn’t editable once it creates the event. The scope parameter must be kAudioUnitScope_Global, and the element index should be 0.
