<!--
{
  "availability" : [
    "iOS: 12.0.0 -",
    "iPadOS: 12.0.0 -",
    "macCatalyst: 13.1.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CarPlay",
  "identifier" : "/documentation/CarPlay/CPMapTemplate/present(navigationAlert:animated:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "CarPlay"
    ],
    "preciseIdentifier" : "c:objc(cs)CPMapTemplate(im)presentNavigationAlert:animated:"
  },
  "title" : "present(navigationAlert:animated:)"
}
-->

# present(navigationAlert:animated:)

Displays a navigation alert on the map template.

```
func present(navigationAlert: CPNavigationAlert, animated: Bool)
```

## Parameters

`navigationAlert`

The navigation alert to display.

`animated`

To animate the display of the alert, set to <doc://com.apple.documentation/documentation/Swift/true>; otherwise, set to <doc://com.apple.documentation/documentation/Swift/false> to immediately display the alert.

## Discussion

This method has no effect when the map template is already displaying a navigation alert. Dismiss the current alert before presenting a new one.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)