Click here to Skip to main content
15,946,988 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:

I am in a need of help to solve my problem.
I have a list control which has no of rows as item. I am able to draw those all rows at a time in Clist. But, my requirement is to increase the height of a specific row dynamically in the Clist.
For drawing all rows. I am using measureitem.

Please help me..

Thanks in advance.

1 solution

This article should help you customise your list class for variable height items.
Another Flexible ListView Control[^]
Share this answer
Sarat Chandra Sannidhiraju 3-Nov-11 13:27pm    
Thanks, Zasky for your quick response. I think this solution which you have provided is helpful for fore coming requirements.
But, I want solution in C++ CListCtrl. If you have any other solution related to the C++ CListCtrl. Please provide me.
Zasky 4-Nov-11 5:06am    
Sorry, stupid mistake. Owner draw with measureitem will only allow you to change all items to the same height, as you have found. If you would consider using an icon for each item in the list you can set different sized icons for each item and the list will resize accordingly. You could use a dummy icon so it is not visible. Not perfect, but worth thinking about.
Finally, consider a custom control. Something like this may work for you:

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900