---
title: "associatedMediaSelectionOption(in:)"
framework: avfoundation
role: symbol
role_heading: Instance Method
path: "avfoundation/avmediaselectionoption/associatedmediaselectionoption(in:)"
---

# associatedMediaSelectionOption(in:)

Returns a media selection option associated with the receiver in a given group.

## Declaration

```swift
func associatedMediaSelectionOption(in mediaSelectionGroup: AVMediaSelectionGroup) -> AVMediaSelectionOption?
```

## Parameters

- `mediaSelectionGroup`: A media selection group in which an associated option is to be sought.

## Return Value

Return Value A media selection option associated with the receiver in mediaSelectionGroup, or nil if none were found.

## Discussion

Discussion Audible media selection options often have associated legible media selection options; in particular, audible options are typically associated with forced-only subtitle options with the same locale. See containsOnlyForcedSubtitles for a discussion of forced-only subtitles.
