I need some way to hide the headers of a TabControl (I'll be switching the selected tab programatically). How can I do this?
Here is the simplest solution:
tabControl.ItemSize = new Size(0, 1);
tabControl.SizeMode = TabSizeMode.Fixed;
Although the height is being set to 1 pixel, the headers will actually disappear completely when you also use TabSizeMode.Fixed.
This has worked well for me.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With