Overview

Windows Forms TabControl is a control used to manage a related group of tab pages. Microsoft documentation states that the TabPages property contains the individual tabs within the control and that each tab is represented by a TabPage object. Tabs can be used to organize multiple pages, property pages, and different groups of controls.


Primary purpose of TABCONTROL: To organize multiple SCADA screens within a single, orderly screen area from the user's perspective and provide access to the relevant screen content through tab selection.
SCADA • TABCONTROL
Overview
Process
Alarms
Trends

Single-Level TAB Structure

A TABCONTROL can contain multiple tab pages. A SCADA screen and its associated user controls can be placed inside each tab page.

No Nested Tabs

This user control can only be used at one level. A second TABCONTROL or another tab structure must not be created inside a TABCONTROL tab page. This rule is a fundamental structural limitation of the control's design.

VERY IMPORTANT: SINGLE-LEVEL TAB ONLY

The most important usage rule for TABCONTROL is that its tab structure must be single-level. The purpose is to combine SCADA screens into a horizontal or vertical group of tabs, display the relevant screen within each tab page, and avoid directing users into a second level of tab hierarchy.

TABCONTROL
├── TABPAGE • Process
│ ├── SCADA screen
│ └── User controls
├── TABPAGE • Alarms
│ ├── Alarm controls
│ └── Alarm information
└── TABPAGE • Trends
├── Chart controls
└── Trend information
Structural limitation: Each TABPAGE above can contain screen content; however, a second tab level cannot be created by placing a new TABCONTROL inside a TABPAGE. The supported structure for TABCONTROL is a single TAB level.

Tab Pages and TABPAGE_COLLECTION

The control's tab structure is defined through the TABPAGE_COLLECTION[] _TabpageItems collection. Each collection item corresponds to the TABPAGE_COLLECTION class, which holds the properties of the tab page displayed to the user. In Windows Forms, the basic TabControl structure is likewise built using the TabPages collection and TabPage objects.

Property Value in Source Code Description
Tab Page Text TabpageText = "TEXT" Specifies the title displayed on the tab.
Tab Page Border Style TabpageBorderStyle = None Specifies the border appearance of the tab page.
Tab Page Color TabpageColor = Transparent Specifies the background color of the tab page.
Tab Page Background Image TabpageBackgroundImage = "" Specifies the background image to be used for the tab page.
Tab Page Tag TabpageTag = "" Stores tag information that can be associated with the tab page.
Screen ID ScreenID = "" The screen identification field associated with the tab page.

In Windows Forms, a tab title can be specified using TabPage.Text; the order of tabs in the collection also affects the order in which they appear on the screen.

Tab Appearance

Tab Appearance determines how tab headers are drawn in the user interface. The source code provides three options.

Option Set Source Value Description
Normal Normal Uses the standard tab appearance.
Buttons Buttons Displays tabs with a button-like appearance.
Flat Buttons Flatbuttons Provides a flatter button appearance.

Tab Alignment

Tab Alignment is used to determine the position of tab headers on the TABCONTROL. Windows Forms TabControl also supports positioning tabs at the top, bottom, left, or right.

Option Set Source Value Usage
Top Top Tabs are positioned at the top.
Bottom Bottom Tabs are positioned at the bottom.
Left Left Tabs are positioned on the left.
Right Right Tabs are positioned on the right.

Tab Behavior and Sizing

TABCONTROL includes properties that determine not only where tabs appear, but also how tab headers respond to user interaction and adapt to the available space.

Property Source Value Description
Multiline Multiline = false Determines whether tabs can span multiple rows when necessary.
Hot Track HotTrack = false Controls whether a visual highlight is applied when the pointer moves over a tab.
Show Tooltips ShowToolTips = false Determines whether tooltips are displayed over tabs.
Size Mode SizeMode = Normal Determines the width and sizing behavior of tabs.
Tab Item Size TabItemSize = 75 × 18 Defines the dimensions of a tab item when fixed sizing is used.
Use Icons UseIcons = false Determines whether icons are used on tabs.
Draw Mode DrawMode = Normal Determines whether tabs are rendered normally or drawn by the user.
Padding Padding = (0, 0) Specifies the additional spacing inside a tab header.

Windows Forms documentation defines SizeMode as the property that determines how tabs are sized and ItemSize as the property that specifies the dimensions of tab items. It also states that SizeMode must be set to Fixed to change the width of ItemSize.

Option Set Source Value Description
Normal Normal The standard tab-sizing behavior.
Fill to Right Filltoright Intended to fill the available width toward the right of the tab row.
Fixed Fixed Creates tabs using the specified fixed dimensions.

General Properties

The following properties define the basic operating and visual settings of the TABCONTROL user control. The initial values from the source code have been preserved.

Property Source Value Description
Control Type UCType = TABCONTROL Specifies the type of the user control.
Update Interval UpdateInterval = 1000 Defines the control's update cycle in milliseconds.
Decimal Places DecimalPoint = 0 Specifies the decimal-place setting used for numerical displays.
Control Background Color UCBackColor = Transparent Specifies the background color of the control.
Control Text Color UCForeColor = Black Specifies the text color of the control.
Control Font UCFont = Times New Roman, 12 Specifies the default font of the control.
Tab Tag TabTag = 18839686 The tab tag field of the control.
Tab Page Items TabpageItems The collection of tab pages created under the control.

Option Sets

The enumerated options used in TABCONTROL can be summarized using the Option Sets below. These values are taken directly from the enum definitions in the supplied source code.

Set Options
GNTabGorunus Normal • Buttons • Flat Buttons
GNBasitKonum Top • Bottom • Left • Right
GNBoyutModu Normal • Fill to Right • Fixed
GNCizimModu Normal • Owner Draw

Applications in SCADA Screens

The primary purpose of TABCONTROL is to organize different screen contents belonging to the same working area under a tab-based layout. For example, the following structure can be created within a single-level TABCONTROL:

Process

Main process operation screens and their associated user controls.

Alarms

Alarm lists, alarm indicators, and operator notifications.

Trends

Graphical monitoring of historical and current data.

Maintenance

Equipment maintenance, status, and auxiliary system screens.

Important design principle: TABCONTROL should be used to organize related screen groups at a single tab level, not to nest one SCADA screen hierarchically inside another.

Recommended Configuration Sequence

When creating a TABCONTROL, planning the tab structure first and then defining the tab pages and the SCADA screens to be displayed on those pages leads to a more organized result.

1 Create TABCONTROL
2 Select tab alignment
3 Define tab pages
4 Associate screen IDs
5 Configure appearance and size
Final check: Once configuration is complete, verify that each tab page displays the correct screen and that no second TABCONTROL exists inside any tab page.

Technical Reference and Windows Forms Infrastructure

Windows Forms TabControl is designed to manage a group of related tab pages. Microsoft documentation states that tabs are stored in the TabPages collection, that each tab is a TabPage object, and that the selected tab can also be changed programmatically.

According to the supplied source code, this user control uses the Windows Forms approach to combine SCADA screens under tabs. It is therefore important to distinguish between the implementation of these features in the control's own source code and the general behavior of the Windows Forms infrastructure.

Conclusion

TABCONTROL is a tab control designed to organize multiple SCADA screens within an interface that is more structured, easier to understand, and more accessible to operators. Its tab appearance, alignment, sizing, tooltips, icon usage, drawing mode, and tab page properties make it possible to organize different screen groups under a single control.

Most important rule: TABCONTROL must be used at only one level. A TABCONTROL can contain tab pages, but a second TABCONTROL or nested tab structure must not be created inside those tab pages.