How to get expand the height of ListView control so that no scrollbars will show?

D

deerchao

I set ListView.Dock to Top, but how can I get the desired height to
avoid it to show vertical scrollbar?

I mean is there something like ListView.ClientSize or
ListView.VirtualHeight?

Thanks!
 
N

Nicholas Paldino [.NET/C# MVP]

I don't think there is a method to tell you this outright. Instead, I
think you would have to adjust the height of the ListView until the
scrollbar is not displayed anymore (and you will probably need to make some
calls to the GetScrollInfo or GetScrollBarInfo API functions to find this
out).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top