How do I force CListCtrl to keep its scrollbar?
The standard control doesn't seem to support your desired behavior.
You can either create enough entries to make the scrollbar visible, or you can create your own control to implement it however you like. The inbetween will be the ownerdrawn style, but this is not the case for the scrollbar.
BTW: what would be the reason the scrollbar is visible all the time in the list control?
source to share
Considering you're trying to get a nice view of a report with columns that fit exactly - no horizontal scrolling and no ugly gray bar instead of scrolling.
From memory in the report view, you can add the last column that will fill the rest of the space and cannot be attributed to size. I can't seem to find any suitable code on MSDN at the moment, recalling vaguely the -1 size for the column.
If you keep resizing the columns, I would do this when: - the application finishes adding / removing a set of new items to the report - the user resizes the report window
Also consider why users can't adjust the column size to what they want?
source to share