Solved

how to scroll to last item of a listview

Posted on 2009-03-31
3
576 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

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Microsoft Reports are based on a report definition, which is an XML file that describes data and layout for the report, with a different extension. You can create a client-side report definition language (*.rdlc) file with Visual Studio, and build g…
Windows Script Host (WSH) has been part of Windows since Windows NT4. Windows Script Host provides architecture for building dynamic scripts that consist of a core object model, scripting hosts, and scripting engines. The key components of Window…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

708 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

21 Experts available now in Live!

Get 1:1 Help Now