Questions tagged [common-controls]

A set of extended windows desktop controls like TreeView, ListView, ProgressBar and TrackBar. Available as ActiveX mscomctl.ocx library and very popular in Visual Basic and Delphi. Superseeded by current ui libraries but still working today.

The Windows Common Controls are a set of standardized user interface components. They originated in Windows 3.11 and were implemented by COMMCTRL.DLL (later named COMCTL32.DLL in Windows 95). Information about the history of the common controls is available here.

Notable controls (which where fancy in the 1990s) are:

  • TreeView - display hierarchical data
  • ListView - display lists with icons (comparable to the lists in the windows explorer application)
  • ProgressBar - a component which displays application progress
  • StatusBar - a way to display status messages in a desktop application window.

MSDN has a complete list of the provided controls.

The controls are distributed with the operating system and coupled to the .

To maintain backwards compatibility, several versions of the controls may exist on a given system. Applications have to specify by an application manifest, which version of the controls should be used.

Nowadays the controls still work, but are replaced by modern user interface toolkits (like or )

102 questions
0
votes
1 answer

Elements in tabs WinAPI

How can I add some elements(window) in my tab? Use these: INITCOMMONCONTROLSEX icex; TCITEMW tie; WM_CREATE: icex.dwSize = sizeof(INITCOMMONCONTROLSEX); icex.dwICC = ICC_TAB_CLASSES; InitCommonControlsEx(&icex); Tab =…
lostsky25
  • 85
  • 1
  • 10
0
votes
1 answer

Common Controls on a Transparent Window?

While there are lots of variations of the question, there doesn't seem to be a specific answer to a simple case of wanting to use built-in common controls on a transparent window using Win32. I don't want the controls to be transparent, I just…
user3161924
  • 1,849
  • 18
  • 33
0
votes
2 answers

CListCtrl with style LVCFMT_FIXED_WIDTH not working with default Windows.Common-Controls

I use the LVCFMT_FIXED_WIDTH style to prevent user columns sizing. m_ListCtrl.InsertColumn(0, _gszColumnLabel[0], _gnColumnFmt[0], LVCFMT_FIXED_WIDTH, _gnColumnWidth[0], -1); What I have discovered only by hasard, this works in Unicode, but not in…
Tom Tom
  • 1,127
  • 11
  • 25
0
votes
1 answer

Window with SysMonthCal32 class doesn't respond to WM_SETFONT

I'm not sure what am I doing wrong. I have a functionality in my CDialog-based MFC app to increase the font in some common controls. It is done by sending them WM_SETFONT message with a larger font: //No error checks for brevity HFONT hFnt =…
c00000fd
  • 20,994
  • 29
  • 177
  • 400
0
votes
1 answer

Problem with subclassing richedit using GWL_WNDPROC

I do this exact thing for both edit and richedit but for the latter there is an access violation, why? The same thing happens when done for tabctrl too. What am I doing wrong? How can I get it to work? WNDPROC OriginalProc; LRESULT CALLBACK…
0
votes
1 answer

How to attach a band to the right side of CReBar control

On my frame window I have a CReBar control with non-movable bands on several lines. On the last line there are two bands, which currently aligned to the left, the second immediately after the…
Ilia
  • 425
  • 2
  • 10
0
votes
0 answers

Can't change edit text background when using Common Controls 6.0

I'm working on a Win32 C++ GUI Desktop application. All the edit text are created statically in the resource file and their background is changed in the DialogBox routine using the WM_CTLCOLOREDIT and WM_CTLCOLORSTATIC messages. case…
user3121071
  • 21
  • 2
  • 4
0
votes
1 answer

PrintDlg Function (64-bit) - Works in Debugger, Crashes when Not

I am porting some Win32 code to Win64. The old code uses PrintDlg(), and runs fine on all versions of Windows (32 and 64 bit). The new code does not! If I set up an all-zeroes PRINTDLG structure in my Win64 application, placing "120" in the…
biowizard
  • 61
  • 1
0
votes
2 answers

Need help understanding LVITEM state and stateMask

I'm confused. The LVITEM structure states: state Type: UINT Indicates the item's state, state image, and overlay image. The stateMask member indicates the valid bits of this member. Bits 0 through 7 of this member contain the item state flags. This…
Adrian
  • 10,246
  • 4
  • 44
  • 110
0
votes
0 answers

draggable separator C windows control?

In many windows such as Device-Manager and Regedit, we see a vertical separator that divides two white child windows. These separators can be dragged side to side using the mouse. Is there a windows control or native common control that can be used…
user980058
  • 511
  • 7
  • 18
0
votes
0 answers

MSCOMCTL.OCX CVE-2012-1856 and CVE-2012-0158 ActiveX vulnerabilities in VB6 applications

My company distributes a reminder-tracking VB6 program to clients that sends out email reminders about deadlines and tracks user replies. Recently, we were approached by a prospective client who is concerned about VB6 vulnerabilities. He sent us a…
user2437443
  • 2,067
  • 4
  • 23
  • 38
0
votes
2 answers

Is it possible to lock memory used by common controls in my application?

I'm writing an application that encrypts its data. It can then display it unencrypted using the app's UI after a user enters password. My goal is to minimize exposure of plaintext data while in RAM. For that I want to prevent swapping it to disk as…
c00000fd
  • 20,994
  • 29
  • 177
  • 400
0
votes
1 answer

Win32 ListView common control re-draw issue

I have got a list view common control in one window. I have a mechanism that updates the list from within the same window (it works like a charm). However, I got this requirement that I have to update the view from an outside entity, like a dialog…
Vijay Kumar Kanta
  • 1,111
  • 1
  • 15
  • 25
0
votes
1 answer

How to enable visual styles on common controls in CDialog created from a DLL?

I have a DLL that may display a dialog window using the following MFC code: void ShowMyDialog() { BOOL bInitted = SUCCEEDED(::CoInitializeEx(NULL, COINIT_APARTMENTTHREADED | COINIT_DISABLE_OLE1DDE)); INITCOMMONCONTROLSEX InitCtrls; …
c00000fd
  • 20,994
  • 29
  • 177
  • 400
0
votes
1 answer

Windows Common Controls (Using specific version)

I need to use Windows Common Controls v6.0 to see new style UIs. I know I can do it by a manifest dependency but when I haven't access to the manifest (or source code... it's not my app but I have a DLL which will be attached to the process and…
rez
  • 316
  • 1
  • 3
  • 18