|
-
Sep 7th, 2000, 03:53 PM
#1
How do i put one of those column headers in a listview control, like in Outlook Express, that sorts the column contents??
I know how to sort, so u don't need to write out all of that stuff...
-
Sep 7th, 2000, 04:25 PM
#2
Fanatic Member
set the View property to 3, then goto the custom properties screen. goto the column headers tab and add the correct header names, when you run it, it'll work!
GWDASH
[b]VB6, Perl, ASP, HTML, JavaScript, VBScript, SQL, C, C++, Linux , Java, PHP, MySQL, XML[b]
-
Sep 7th, 2000, 05:33 PM
#3
those two steps arn't working, is there something i'm skipping??
-
Sep 7th, 2000, 06:05 PM
#4
Fanatic Member
ok
try this in your list view columnclick event
assuming the name of your list view is lstView
the following will toggle the sorting in ascending/descending order
Private Sub lstView_ColumnClick(ByVal ColumnHeader As MSComctlLib.ColumnHeader)
With lstView
.SortKey = ColumnHeader.Index - 1
If .SortOrder = lvwAscending Then
.SortOrder = lvwDescending
Else
.SortOrder = lvwAscending
End If
.Sorted = True
End With
End Sub
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
|