no

Learn to Order Tabcontrol in C#

This bug is annoying. I am currently developing a windows mobile application and I am using the TabControl control. I dont have any problem ...

This bug is annoying. I am currently developing a windows mobile application and I am using the TabControl control. I dont have any problem with it adding TabPages etc.

The only problem I have is when I tried to debug the order of TabPages get shuffled. This is a problem because my action depends on the tab index.

I don't know what's causing this, but I thought re adding the TabPages on RunTime might work, and it really work for me. So here's the pseudocode.


tabControl.TabPages.Clear(); //first clear the tabcontrol
//then readd your tabs
tabControl.TabPages.Add(tabOne);
tabControl.TabPages.Add(tabTwo);
tabControl.TabPages.Add(tabThree);
tabControl.TabPages.Add(tabFour);


Remember this code should be add after the InitializeComponent method in the main constructor.

Related

c# 8687252371786407528

Post a Comment Default Comments

Outsourcing

Are you looking for freelancers in the Philippines? Get in touch.

Donations

If you like what I do, you can support this channel by buying me a coffee. I would be grateful for your contribution! Your donations will help me create more FREE online courses and learning materials for programmers and remote workers.

item