473,498 Members | 1,544 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ListView - Automatically scrolling


If I have a Listview (in report mode) and theres several hundred items
in it, is there any way programatically, to automatically scroll to
the last item...Eg. the same thing that would happen if you were to
click the list to give it focus, and then press the END key.

I think I could do it by Selecting the last Item, but I'd rather not
unselect anything the user had selected...I have multiselect FALSE

Also, another question about listviews, anyone know of a Dot Net
component that I can use as an alternative to Listview. VbAccellerator
has one "Grid2", but its for VB5 and 6, and doesn't seem to work in
Dot Net. I'd like to have something Similar to how Outlook displays
Messages, Eg. Several Columns and then one Column directly underneath
that spans the whole width of the control.

TIA for any help,
Scott

Nov 20 '05 #1
4 1464
OT - but 'several hundred items' in a listbox implies that you don't like
your users. Far too many to be usable. Do you give them a method of
filtering?
"Scott H" <x@y.com> wrote in message
news:pf********************************@4ax.com...

If I have a Listview (in report mode) and theres several hundred items
in it, is there any way programatically, to automatically scroll to
the last item...Eg. the same thing that would happen if you were to
click the list to give it focus, and then press the END key.

I think I could do it by Selecting the last Item, but I'd rather not
unselect anything the user had selected...I have multiselect FALSE

Also, another question about listviews, anyone know of a Dot Net
component that I can use as an alternative to Listview. VbAccellerator
has one "Grid2", but its for VB5 and 6, and doesn't seem to work in
Dot Net. I'd like to have something Similar to how Outlook displays
Messages, Eg. Several Columns and then one Column directly underneath
that spans the whole width of the control.

TIA for any help,
Scott

Nov 20 '05 #2
Hi Scott,

Almost the same answer as Scott, with a little bit difference, when you use
the listview have foreever your eyes on Windows Explorer.

In mine opinion is therefore the solution to create asside of your listview
a treeview the same as with Explorer.

You users will like you because you have taken a solution they already know.

I hope this helps?

Cor
Nov 20 '05 #3
* Scott H <x@y.com> scripsit:
If I have a Listview (in report mode) and theres several hundred items
in it, is there any way programatically, to automatically scroll to
the last item...Eg. the same thing that would happen if you were to
click the list to give it focus, and then press the END key.


Call the last item's 'EnsureVisible' method.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #4
Call the last item's 'EnsureVisible' method.


Thanks Herfried, that did just what I wanted.

I'll give the treeview a think Cor, But it may not be the 'look' I'm
after.

Several hundred may have been an exageration, about 50 at most, and
plenty of filtering options, it was just the "view all" option that
was a bit awkward, having to scroll down to end, which was were users
will most want to look at, I could have done it in reverse order I
suppose.

Thanks for your help.

Nov 20 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
3837
by: Wiktor Zychla | last post by:
today we've found a critical issue regarding the ListView from Windows.Forms. it was confirmed on several machines with Win2K and XP. here's the problem: create a ListView with about 50000 rows....
1
10549
by: SlantyOD | last post by:
Hi All, I'm trying to tie two ListViews together so that when the user scrolls one, the other stays 'in sync'. Since there are no OnScroll events, and the scroll bar position is unavailable,...
0
2850
by: Tim Bücker | last post by:
Hello. Is it really not possible to hide the scrollbars of a listview ( this.listview.Scrollable = false; ) but do some scrolling anyway ( for instance: PostMessage(this.listview.Handle,...
3
3268
by: Rob Richardson | last post by:
Greetings! I am attempting to display data in tabular form using a ListView control in detail mode. This is for a program I originally wrote in VB6. In VB6, I would add an item to the...
4
9034
by: Lars Netzel | last post by:
I have a long list of Items in a ListView... if I scroll down to something that is not visible without scrolling and then click on it I open another window where you can work with the details of...
0
1851
by: Danny Tuppeny | last post by:
Hi all, I have a need to display a message list in the same way as Outlook Express/Thunderbird displays new posts (and probably most other newsreaders, like the one you're using now!). I know...
5
2355
by: Martin Horn | last post by:
Hi all, I want to implement a listview with editable subitems and I assume the easiest way is to overlay a textbox over the item to be edited. With this in mind I have come up with: Using...
5
1783
by: --== Alain ==-- | last post by:
Hi, Several months ago i've asked some information about the best way how to have some particular columns (progress bar, checkbox, images, color picker,...) in a ListView component. It seems...
0
1705
by: Jarppi | last post by:
Hi All, Not sure how to go about this one. I've got a windows form with five ListView controls, each listing the files in a seperate folder. What I want to achieve is this: When I scroll any...
0
7126
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7005
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7168
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6891
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
4595
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3087
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1424
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
659
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
293
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.