Solved

how to scroll to last item of a listview

Posted on 2009-03-31
3
581 Views
Last Modified: 2012-05-06
Hi, if you have a listview being populated with data; what is the command to automatically scroll to the last item being added to that listview
e.g.

 

lvMyItem = House.items.add("House of character")

lvMyItem.add("¬4,000")

etc..

Open in new window

0
Comment
Question by:borgb002
3 Comments
 

Author Comment

by:borgb002
ID: 24031784
BTW I'm using VB .NET 2008
0
 
LVL 48

Accepted Solution

by:
jpaulino earned 500 total points
ID: 24032028
You can use EnsureVisible()
Example

        Dim item As New ListViewItem

        item.Text = "columm 1"

        item.SubItems.Add("column 2")

        Me.ListView1.Items.Add(item)
 

        item.EnsureVisible()

Open in new window

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

Suggested Solutions

How to remove superseded packages in windows w60 or w61 installation media (.wim) or online system to prevent unnecessary space. w60 means Windows Vista or Windows Server 2008. w61 means Windows 7 or Windows Server 2008 R2. There are various …
The purpose of this article is to demonstrate how we can use conditional statements using Python.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.

895 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

11 Experts available now in Live!

Get 1:1 Help Now