🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: microsoft.public.win32.programmer.ui
Article #4

How do I get a particular item to be visible in listView?

#4
From: Brian Ellis
Date: Wed, 04 Apr 2001 16:08
21 lines
2154 bytes
I am looking for a way to get a particular item to be visible in a WinAPI
listview control.

I've tried using a sendmessage with LVM_ENSUREVISIBLE. This appears to
repaint the
listview, with the appropriate item near the top (but unselected), but the
items appear out of order
(they were in alphabetic order before), and another instance of the
pertinent item appears lower in the
list, this time selected(highlighted).

I've also tried using a sendmessage with LVM_SCROLL. I use LVM_GETTOPINDEX
before the call to
scroll, which typically returns item index 0. After the LVM_SCROLL call
(which returns True, indicating success), another LVM_GETTOPINDEX call
returns item index 0, and no scrolling has taken place.

Can anyone suggest anything?

Thanks in advance,
Brian Ellis
Technical Details
Message-ID: <hGHy6.107$kg.2395@news2.mts.net>
Path: arc1-ca.pugleaf.net!supernews.google.com!sn-xit-03!supernews.com!news-xfer.nuri.net!newsfeed.dacom.co.kr!newsfeed.direct.ca!look.ca!cyclone.bc.net!news-in.mts.net!news2.mts.net.POSTED!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 1091e5,282e27e37b2ad713,start
X-Google-Attributes: gid1091e5,public
X-Google-Thread: f7033,282e27e37b2ad713,start
X-Google-Attributes: gidf7033,public
X-Google-Thread: 10461f,282e27e37b2ad713,start
X-Google-Attributes: gid10461f,public
X-Google-Thread: 110c1b,282e27e37b2ad713,start
X-Google-Attributes: gid110c1b,public
X-Google-ArrivalTime: 2001-04-04 09:08:07 PST
Path: arc1-ca.pugleaf.net!supernews.google.com!sn-xit-03!supernews.com!news-xfer.nuri.net!newsfeed.dacom.co.kr!newsfeed.direct.ca!look.ca!cyclone.bc.net!news-in.mts.net!news2.mts.net.POSTED!not-for-mail
From: "Brian Ellis" <brian@getintouch.ca>
Newsgroups: microsoft.public.win32.programmer.ui,microsoft.public.win32.programmer,comp.os.ms-windows.programmer.controls,borland.public.delphi.winapi
Subject: How do I get a particular item to be visible in listView?
Lines: 24
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2919.6700
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700
Message-ID: <hGHy6.107$kg.2395@news2.mts.net>
Date: Wed, 04 Apr 2001 16:08:45 GMT
NNTP-Posting-Host: 64.59.130.155
X-Complaints-To: admin@mts.net
X-Trace: news2.mts.net 986400525 64.59.130.155 (Wed, 04 Apr 2001 11:08:45 CDT)
NNTP-Posting-Date: Wed, 04 Apr 2001 11:08:45 CDT
Organization: MTS Internet