We have a Windows Mobile app that uses the Tab control from the ControlsEx library. As a form loads a new page is added to the Tab control and is populated with different controls such as TextBoxes etc. depending on settings in a database.
This works fine first time but how do I remove these controls when another database is selected?
If I do Tab1.RemoveTabPage it’s blank next time round, even if I add a new tabpage.
If I add another tab and bring it to the front this works fine for the second time but if the user then selects a previously used database an error occurs when loading the tab page because it says the controls have already been added from the previous time.
What I would really like to do is clear the tab of all controls and re-populate it. Or remove the tabs and add them again. Any ideas? Thanks very much.
This works fine first time but how do I remove these controls when another database is selected?
If I do Tab1.RemoveTabPage it’s blank next time round, even if I add a new tabpage.
If I add another tab and bring it to the front this works fine for the second time but if the user then selects a previously used database an error occurs when loading the tab page because it says the controls have already been added from the previous time.
What I would really like to do is clear the tab of all controls and re-populate it. Or remove the tabs and add them again. Any ideas? Thanks very much.