S
Simanovsky
Hello all,
Could anybody advice how to calculate the width of the
widest item in the ListView?
I need to resize a ListView according to the size of the
strings stored in it, particulary to avoid horizontal
scrolling. To calculate the new dimensions of the control
I tried both overloads of ListView.GetItemRect() while
setting View to View.List and View.Details. But
GetItemRect seems always to return same value for all
indices and setting control width to that does not ensure
absence of horizontal scrolling.
Thanks in advance,
Simanovsky
Could anybody advice how to calculate the width of the
widest item in the ListView?
I need to resize a ListView according to the size of the
strings stored in it, particulary to avoid horizontal
scrolling. To calculate the new dimensions of the control
I tried both overloads of ListView.GetItemRect() while
setting View to View.List and View.Details. But
GetItemRect seems always to return same value for all
indices and setting control width to that does not ensure
absence of horizontal scrolling.
Thanks in advance,
Simanovsky