c# - How can I make my checkedlistbox vertically scrollable when MultiColumn is set to true? -


I have a checklist list, which is 3 rows high, and enough to display approximately 5 elements.

By the time I get less than 15 elements, everything goes fine. However, if I add a sixteenth element, the checklist box displays a horizontal scrollbar that takes 2 item rows, Which means that all items are now just one line.

Worse, if I remove extra items, the horizontal scrollbar stays in place.

I have tried to use:

  mycheckedlistbox.HorizontalScrollbar = false; Mycheckedlistbox.ScrollAlwaysVisible = false;  

But it has no effect.

I use multicolumn = true mode, which is the reason for this misbehavior

Is there any control to prevent horizontal scrollbar from being displayed, and instead a vertical Use the scrollbar?

I have met someone with such a question, but it seems that he did not get an anwser.

Well, looking at the answers from there, and I ran away from some tests, it seems that Impossible, but also, I think you are trying to defeat this objective. If I was in your shoes, I was using a datagrid view with grid lines, which can not be editable. You have more control over what's happening in the grid, and you can customize it much more from the checkedboxes checked. You can have the same effect as you can with DataGridViewCheckBoxColumns only.

(If you want a code sample, post in the comment, and I will alert a quick sample.)


Comments