On Feb 17, 2006, at 2:16 AM, [EMAIL PROTECTED] wrote:

How can you tell how many rows are displayed in a listbox? Say a listbox as 100 rows but only 50 are showing at anyone time? How can you get the value of 50 as a property? (100 = listbox.listcount I believe). This comes up because I am trying to control scrolling. If the user modifies item #75, the listbox would scroll to the top, and the selected item was not be seen (being off the screen to the bottom). I understand that the scrollposition property gives the row number of the first row displayed. But I do not see a way to see the last
row displayed, the number of rows displayed, or otherwise.

I'm not sure why the listbox is scrolling to the top after modification if you don't want it to. But, you can determine the number of visible rows by working with the listbox Height property and g.TextHeight or DefaultRowHeight if you have specified it. An archive search on this would be productive as I know that several have posted code on the visible rows issue, Karen I recall for sure.

Best regards,

Jack



_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to