CanGoBack Property
Collapse the table of content
Expand the table of content

NavigationService.CanGoBack Property

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Gets a value that indicates whether there is at least one entry in the back navigation history.

Namespace:  System.Windows.Navigation
Assembly:  Microsoft.Phone (in Microsoft.Phone.dll)

'Declaration
Public ReadOnly Property CanGoBack As Boolean

Property Value

Type: System.Boolean
true if there is at least one entry in the back navigation history; otherwise, false.

The GoBack method throws an InvalidOperationException exception if there are no entries in the back navigation history. To determine whether there is at least one entry in the back navigation history, check the value of the CanGoBack property.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2017 Microsoft