Scrolling the listbox 
Author Message
 Scrolling the listbox

Good day all,

Is there a way to scroll a list box without the aid of the
vertical scroll bar comes with it. I know that with a list
view control, one can use the ListView_Scroll macro or  
LVM_SCROLL message to scroll the items in it. But I
couldn't find the similar macro or message for a list box.

Any comment is welcomed.

Thanks,

Jason



Mon, 04 Oct 2004 22:43:00 GMT  
 Scrolling the listbox

The following messages scroll the contents of a list box:
LB_SETTOPINDEX
LB_SETCURSEL (some string is selected, too)

MFC has wrappers for them, too (CListBox::SetTopIndex and
CListBox::SetCurSel)

If you want to control scroll position more preciesely, you have to
manipulate scroll bar directly.

--
Sincerely,
Alexander


http://www.RSDN.ru - Russian Software Developer Network


Quote:
> Good day all,

> Is there a way to scroll a list box without the aid of the
> vertical scroll bar comes with it. I know that with a list
> view control, one can use the ListView_Scroll macro or
> LVM_SCROLL message to scroll the items in it. But I
> couldn't find the similar macro or message for a list box.

> Any comment is welcomed.

> Thanks,

> Jason



Mon, 04 Oct 2004 23:33:32 GMT  
 Scrolling the listbox
Thanks, Alexander, for your help.

Jason



Tue, 05 Oct 2004 00:09:39 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Automatic horiz scroll in listbox

2. Horizontal Scroll on ListBox wanted

3. Scrolling a listbox

4. Managing vertical scroll in listbox

5. Automatic horiz scroll in listbox

6. Scrolling a ListBox?

7. Scroll in Listbox

8. Horizontal Scroll in ListBox doesn′t work

9. Scrolling a ListBox Control

10. Scrolling listbox headings and listbox together

11. Listbox without scroll?

12. synchronizing scroll of two listboxes

 

 
Powered by phpBB® Forum Software