Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

Set Scroll position in a list box
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



Report this thread to moderator Post Follow-up to this message
Old Post
Marv Wade
05-28-05 01:55 AM


Re: Set Scroll position in a list box
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 th
e
> 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 th
e
> 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 accomplish
ed
> I would appreciate any reference to who this can be done.
>
> Mav
>
>



Report this thread to moderator Post Follow-up to this message
Old Post
Douglas Marquardt
05-28-05 01:55 AM


Re: Set Scroll position in a list box
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... 
>
>



Report this thread to moderator Post Follow-up to this message
Old Post
Marv Wade
05-28-05 08:55 AM


Re: Set Scroll position in a list box
"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... 
>
>



Report this thread to moderator Post Follow-up to this message
Old Post
John Cleveland
05-28-05 08:55 AM


Re: Set Scroll position in a list box
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.

Report this thread to moderator Post Follow-up to this message
Old Post
J French
05-28-05 08:55 PM


Re: Set Scroll position in a list box
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.
>
> 
>
>



Report this thread to moderator Post Follow-up to this message
Old Post
Marv Wade
05-28-05 08:55 PM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

Visual Basic archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 06:33 PM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.