Welcome to Dream.In.Code
Become a VB Expert!

Join 149,379 VB Programmers for FREE! Get instant access to thousands of VB experts, tutorials, code snippets, and more! There are 2,580 people online right now. Registration is fast and FREE... Join Now!




Listview Help!

 
Reply to this topicStart new topic

Listview Help!

oXiDe
14 Feb, 2008 - 08:15 PM
Post #1

New D.I.C Head
*

Joined: 17 Nov, 2007
Posts: 37



Thanked: 1 times
My Contributions
How does one add info into a listview from the top instead of adding to the bottom

CODE
                    frmMain.lvCF.SortOrder = lvwAscending
                    frmMain.listview.ListItems.Add frmMain.lvCF.ListItems.Count + 1, , sUsername, , ClientFlag
                    frmMain.listview.ListItems(frmMain.lvCF.ListItems.Count).ListSubItems.Add , , lPing, , lPing


this code doesnt work the way i want it to ( its alphabetic sad.gif ) please help me
User is offlineProfile CardPM
+Quote Post

Nayana
RE: Listview Help!
17 Feb, 2008 - 07:03 PM
Post #2

DIC Hawk - 나야나 नयन:
Group Icon

Joined: 14 Nov, 2007
Posts: 824



Thanked: 5 times
Dream Kudos: 175
My Contributions
To add something to the start of the list, just add it at index 1. e.g.
lvwSomething.ListItems.Add 1, , "This goes at the start"

The effect of this will only be visible when its viewmode is set to 'list'.
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 1/7/09 09:23AM

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter

Live VB Help!

VB Tutorials

Reference Sheets

VB Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month