Navigation

RadWizard provides out of the box a basic sequential page navigation, which allows you to navigate through the pages linearly. With the help of RadWizard's events you can follow the state of the control at run time and implement custom pages sequence and page processing validation if necessary.

Linear Navigation

RadWizard’s navigation is enabled by default and it allows you navigating through the pages in linear order. By default, pages will be visited in the order that they are defined in its WizardPages collection.

Conditional Navigation

RadWizard provides the following events, which enable the implementation of conditional (not linear) navigation.

  • SelectionChanging
  • SelectionChanged
  • Previous
  • Next
  • Finish
  • Help
  • Cancel

For the full list of events refer to the Events article.

Here's an example of handling the SelectionChanged event to jump to a particular page when a condition is met.

Example 1: Jump to particular page

private void RadWizard_SelectionChanged(object sender, SelectedPageChangedEventArgs e) 
{ 
    if (e.NewPage == this.page2) 
    { 
        ((RadWizard)sender).SelectedPage = this.page3; 
    } 
} 
Private Sub RadWizard_SelectionChanged(ByVal sender As Object, ByVal e As SelectedPageChangedEventArgs) 
    If e.NewPage = Me.page2 Then 
        DirectCast(sender, RadWizard).SelectedPage = Me.page3 
    End If 
End Sub 

Example 2 in turn demonstrates how to use the Finish event to return to the starting page once the user clicks Finish.

Example 2: Restart the wizard when the Finish button is clicked

private void RadWizard_Finish(object sender, NavigationButtonsEventArgs e) 
{ 
    ((RadWizard)sender).SelectedPage = this.page1; 
} 
Private Sub RadWizard_Finish(ByVal sender As Object, ByVal e As NavigationButtonsEventArgs) 
    DirectCast(sender, RadWizard).SelectedPage = Me.page1 
End Sub 

See Also

In this article
Not finding the help you need? Improve this article