|
-
Oct 9th, 2003, 02:15 PM
#1
Thread Starter
Addicted Member
ListView & ICompare interface
Hi to all,
How to sort ListView columns based on particular column (Windows Explorer style) in VB.net
I come to know from Help that in "ColumnClick" event of I have to write following code:
VB Code:
Private Sub ListView1_ColumnClick(ByVal sender As Object, ByVal e As System.Windows.Forms.ColumnClickEventArgs) Handles lvwItem.ColumnClick
Me.ListView1.ListViewItemSorter= ?
Me..ListView1.Sort()
End Sub
?= a class instance having ICompare interface
But I dont understanding how to do it
Please help
Thanks
Last edited by parminder; Oct 9th, 2003 at 02:21 PM.
-
Oct 9th, 2003, 02:29 PM
#2
Thread Starter
Addicted Member
Please read the code as "
VB Code:
Private Sub ListView1_ColumnClick(ByVal sender As Object, ByVal e As System.Windows.Forms.ColumnClickEventArgs) Handles listView1.ColumnClick
Me.ListView1.ListViewItemSorter= ?
Me..ListView1.Sort()
End Sub
-
Oct 13th, 2003, 11:44 AM
#3
Thread Starter
Addicted Member
Not any Guru has seen ?
-
Oct 13th, 2003, 12:10 PM
#4
What is it that you don't know how to do? Implement IComparer? Or you don't know what implements it already? I've seen examples posted on the forums before of sorting a Listview you may want to try searhcing.
-
Oct 13th, 2003, 01:05 PM
#5
Frenzied Member
Yes it been done before. I did an example on how to do it a while back. Search the forum and you will find it.
-
Oct 15th, 2003, 01:39 PM
#6
Thread Starter
Addicted Member
Thanks Edneeis and DevGrp
I found a example at the forume. I will try it. If some problem occurs I will ask you.
Thans
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|