Add a UserControl
You can use the UserControl to create a reusable control for your Wisej.NET application. In our case, we want to be able to navigate between pages of an application. On each page, we want the same navigation menu. So it makes sense to use a UserControl because it can be reused on each page.
To create a UserControl:
In the Solution Explorer, right-click and choose Add->New Item
From the menu that pops up, choose "Wisej.NET 4" and then "User Control". (Alternatively choose Wisej.NET 3 if you are using Wisej.NET 3)

Name your UserControl (Ie "Nagivation.cs") and click "Add"
Add some controls from the toolbox- in our case, we added a combobox and a label. Add some items to the combobox- ie "Page1", "Page2", "Page3".
Attach to the SelectedIndexChanged event of the combobox and add the following code to navigate between pages:
Compile the project. Open the designer and you will now see the usercontrol. Click and drag it into the page. Repeat this for each page in the application.
Last updated
Was this helpful?

