Newer Version Available

This content describes an older version of this product. View Latest

setSelectedNavigationItem() for Lightning Experience

Sets the selected navigation item to a specific ID. This method works only in Lightning console apps.

Arguments

Name Type Description
developerName string The ID of the navigation item.

Sample Code

This Aura component has a button that, when pressed, sets the specified ID as the selected navigation item.

Component code:

Controller code:

Response

This method returns a promise that, upon success, resolves to true.