Solved

How do you always keep the last item visible on a listview

Posted on 2004-08-13
4
323 Views
Last Modified: 2010-04-23
How do you always keep the last item visible on a listview?
As items are added to a listview I want to see the last item added ,scrolling
0
Comment
Question by:visualbasic
4 Comments
 
LVL 25

Accepted Solution

by:
RonaldBiemans earned 50 total points
ID: 11791927
use something like this

      Dim x As Integer
      With ListView1
      For x = 1 To 20
      .ListItems.Add Key:="foo" & x, Text:="foo" & x
      Next x
      .SelectedItem = .ListItems("foo20")
      .SelectedItem.EnsureVisible
      End With
      End Sub
0
 
LVL 28

Expert Comment

by:iboutchkine
ID: 11792092
or just select the last row
listView1.Items(i).Selected = True

where i is count of the rows
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction When many people think of the WebBrowser (http://msdn.microsoft.com/en-us/library/2te2y1x6%28v=VS.85%29.aspx) control, they immediately think of a control which allows the viewing and navigation of web pages. While this is true, it's a…
It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, just open a new email message. In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now