473,699 Members | 2,530 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Alignment problem in TabControl

Hi all

In a Visual Studio 2005 C# project, I have a simplest tabcontrol with two
tabpages. When I set tab control's Alignment property to Right, tab texts
(captions) disappear.
Does anybody know how to fix this?

I tried this on two computers, at work and at home, both with Windows XP
with latest service packs, and Framework 2.0 and 3.0 with latest SP.

Thank you

Jan 27 '08 #1
1 3455
This is a Visual Styles issue. TabControl does not support Visual Styles for
alignments other than top.

You can use SetWindowTheme via Interop to disable Visual Styles for the
TabControl whilst keeping it enabled for other controls, or you can
ownerdraw the tabcontrol.

Alternatively, use a third party TabControl.

On my site you will find a two TabControls which correct this issue. The
first (TabControlEx) is a Framework 1.1 TabControl and the second
(TabControl) is a Framework 2.0 TabControl. The second doesn't have all the
features of TabControlEx, but it Implements Visual Styles much better.

Mick Doherty
"Alex K." <Al***@discussi ons.microsoft.c omwrote in message
news:EA******** *************** ***********@mic rosoft.com...
Hi all

In a Visual Studio 2005 C# project, I have a simplest tabcontrol with two
tabpages. When I set tab control's Alignment property to Right, tab texts
(captions) disappear.
Does anybody know how to fix this?

I tried this on two computers, at work and at home, both with Windows XP
with latest service packs, and Framework 2.0 and 3.0 with latest SP.

Thank you

Jan 27 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

by: CANCERMAN | last post by:
Hi everyone, I'm another newbie with C# so bare with me :) OK, here is what I wanted to do: Create a TabControl that will have some TabPages aligned to the TOP and some TabPages aligned to the BOTTOM. Is it even possible? Currently I created 2 TabControls, one with Top alignment and the other with Bottom alignment, but that's kinda cheating my way in, and it doesn't look good. Any good suggestions? Thanks a lot
by: Tamir Khason | last post by:
How be able to manage more deeply UI of TabControl and TabPage For example - I want to manage border color, change color of TabPage reef, eliminate spaces from both sides of the reef, so I bould custom control that inherit all information from TabPage, but how to access those properties, not supported by standart interface??? Thank you
by: Patrick McGuire | last post by:
I want to place a tabControl with almost identical properties on several forms. I think the best way is to define a UserControl that inherits System.Windows.Forms.TabControl, and place all my controls on it. The problem is that I don't know how to bring up the graphical design interface for the TabControl. I suppose I COULD just design it as a UserControl and place a TabControl on it, but that seems a bit... inelegant (I'm going to...
by: Simon Verona | last post by:
I have a few hundred forms in my application. All are based on a custom base form class. I decided that I wanted to globally change the look and feel of many of the controls in my application - including the tab control. I did this by writing a component that I attached to the form. The component has a "Start" function which takes the form as a paramater. This cycles through all the controls on the form, changes some of the properties...
by: =?Utf-8?B?U3RldmVU?= | last post by:
I want to create tabs in the TabControl that are aligned on either the right or left side, but no text shows when doing this. Is there an issue here or a work around. Text for tabs on top or bottom are just fine. I'm using VS 2005. -- ----------- Thanks, Steve
by: Gav | last post by:
I am writing an application where I will have a TabControl and 3 styles of Tabs to go in it, each containing different controls. The tabs will be added to the tabcontrol when items are clicked on in a TreeView. So the the application starts by displaying no tabs and adds them in as required. There could be any number of each tab (0 upwards). What is the best way of me doing this? Should I create 3 custom controls that extend TabPage?...
by: bertie78 | last post by:
Hi all, New poster here! I'm having some difficulty updating a tabcontrol cross-threads. The general idea is : the main thread is the owner of the tab control and the form controls. However, due to the vast amount of data to populate listviews within the tabs, I have created a worker thread (an implementation of a BackgroundWorker) to form the data and populate a tabcontrol 'offline', so that it doesn't interfer with (i.e freeze) the UI. ...
by: Jamey | last post by:
Ran into an inconvenience with TabControls yesterday. I found a partial explanation from Allen Browne on the MS message boards explaining when it happens, but not why. I thought Stephen Lebans (who's done a little work with this for his multi-colored listbox class), or someone else might've figured this out. Here's the scenario: DBs created on Windows XP using A2K7 are apparently incapable of displaying TabControl transparency....
by: Claudia Fong | last post by:
Hi, I added a tabcontrol in a panel in my form. My tabcontrol have more than 3 pages.. each page contains textboxes, combobox, checkbox. I want to disable the items of each of the page of the tabcontrol (so that the user won't be able to change the values in the textboxes, combobox, checkbox) without the tabcontrol turn into grey.
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.