This project has moved. For the latest updates, please go here.
1

Closed

Next Button Issues When Inserting Pages

description

I discovered a bug that occurs during the WizardPage.Commit event.

If you Insert pages during the Commit event that appear after the WizardPage that just triggered the Commit event then it skips past all the inserted WizardPage controls.

For example:
Private Sub WizardPage1_Commit(sender As Object, e As AeroWizard.WizardPageConfirmEventArgs) Handles WizardPage1.Commit
    Dim pages As List(Of AeroWizard.WizardPage) = New List(Of AeroWizard.WizardPage)

    'Dynamically create the WizardPages
    Dim row As DataRowView
    For Each index As Integer In checkedListBox.SelectedIndices
        row = DirectCast(checkedListBoxCameras.Items(index), DataRowView)
        pages.Add(CreateCameraWizardPage(row("Name").ToString, row("IpAddress").ToString))
    Next

    'Insert the pages
    WizardControl1.Pages.InsertRange(2, pages)
End Sub
That event will skip all pages inserted to select the page that appeared next in the designer.
Closed Mar 13 at 5:21 PM by dahall
No response.

comments

dahall wrote Jan 12 at 6:14 PM

Check to make sure the NextPage property on your current page is set to null or set to the first page you've inserted.

wrote Mar 13 at 5:21 PM