---
title: primaryAction
framework: uikit
role: symbol
role_heading: Instance Property
path: uikit/uidocumentviewcontroller/launchoptions-swift.class/primaryaction
---

# primaryAction

The launch scene’s primary action.

## Declaration

```swift
@NSCopying var primaryAction: UIAction? { get set }
```

## Mentioned in

Customizing a document-based app’s launch experience

## Discussion

Discussion Set this property to customize the primary action’s button in the document launch scene. If you don’t set this property, the system adds a default Create Document button to the title view.

## See Also

### Adding actions

- [secondaryAction](uikit/uidocumentviewcontroller/launchoptions-swift.class/secondaryaction.md)
