| Author |
Set Scroll position in a list box
|
|
| Marv Wade 2005-05-27, 8:55 pm |
| I currently populate a list box, (sorted is set to true) with a group of.
names. There is a text box that allows entering a part of a name. As the
name is entered the I remove all names not matching what has so far been
entered.
This works OK but I would like to modify it so that instead of removing the
non-matching names when information is entered into the text box the list
box is scrolled so that names that match what has been entered into the
text box will appear at the top of the list box.
I have been unable to find any information on how this could be accomplished
I would appreciate any reference to who this can be done.
Mav
| |
| Douglas Marquardt 2005-05-27, 8:55 pm |
| Hi Marv:
Perhaps this is what your looking for:
http://support.microsoft.com/defaul...kb;en-us;141027
hth,
Doug.
"Marv Wade" <NG@columbus.rr.com> wrote in message news:OGv0cYwYFHA.796@TK2MSFTNGP09.phx.gbl...
> I currently populate a list box, (sorted is set to true) with a group of.
> names. There is a text box that allows entering a part of a name. As the
> name is entered the I remove all names not matching what has so far been
> entered.
>
> This works OK but I would like to modify it so that instead of removing the
> non-matching names when information is entered into the text box the list
> box is scrolled so that names that match what has been entered into the
> text box will appear at the top of the list box.
>
> I have been unable to find any information on how this could be accomplished
> I would appreciate any reference to who this can be done.
>
> Mav
>
>
| |
| Marv Wade 2005-05-28, 3:55 am |
| It's close but not exactly. The sample you referred to highlights the first
name matching the text box but that may be at the bottom of the visible
portion of the list box. What I want to do is to have the first matching
entry scroll to the top visible position of the list box.
This does, however, a marked improvement in the code I have been using to
display matches
Marv
"Douglas Marquardt" <no_spam@dummy.com> wrote in message
news:e$BJTkwYFHA.1368@tk2msftngp13.phx.gbl...
> Hi Marv:
>
> Perhaps this is what your looking for:
>
> http://support.microsoft.com/defaul...kb;en-us;141027
>
> hth,
>
> Doug.
>
>
> "Marv Wade" <NG@columbus.rr.com> wrote in message
> news:OGv0cYwYFHA.796@TK2MSFTNGP09.phx.gbl...
>
>
| |
| John Cleveland 2005-05-28, 3:55 am |
| "Marv Wade" <NG@columbus.rr.com> wrote in message
news:OpSOEKxYFHA.3584@TK2MSFTNGP12.phx.gbl...
> It's close but not exactly. The sample you referred to highlights the
> first name matching the text box but that may be at the bottom of the
> visible portion of the list box. What I want to do is to have the first
> matching entry scroll to the top visible position of the list box.
>
> This does, however, a marked improvement in the code I have been using to
> display matches
>
> Marv
I believe the TopIndex property is what you are looking for.
>
> "Douglas Marquardt" <no_spam@dummy.com> wrote in message
> news:e$BJTkwYFHA.1368@tk2msftngp13.phx.gbl...
>
>
| |
| J French 2005-05-28, 3:55 pm |
| On Fri, 27 May 2005 17:49:48 -0400, "Marv Wade" <NG@columbus.rr.com>
wrote:
>I currently populate a list box, (sorted is set to true) with a group of.
>names. There is a text box that allows entering a part of a name. As the
>name is entered the I remove all names not matching what has so far been
>entered.
If you do a Google Groups search for : virtual list box j french
Then you will find some fairly crappy code that turns a listbox inside
out.
What I think you would really like to do, is to /exclude/ the
definitely non matching names.
Keep the real data outside the Listbox, and manipulate an array of
numbers (pointers) into the total data set.
| |
| Marv Wade 2005-05-28, 3:55 pm |
| Ah, that is exactly what I was looking for.
Thanks.
Marv
"John Cleveland" <jwcleve@pacbell.net> wrote in message
news:gVPle.2216$kS3.1562@newssvr21.news.prodigy.com...
> "Marv Wade" <NG@columbus.rr.com> wrote in message
> news:OpSOEKxYFHA.3584@TK2MSFTNGP12.phx.gbl...
>
> I believe the TopIndex property is what you are looking for.
>
>
>
>
|
|
|
|