Another ListView question

  • Thread starter Thread starter whistler
  • Start date Start date
W

whistler

I have a listview in a form where I am trying to permit users sorting by clicking on column headers.

I came up with this.....

Private Sub ListView1_ColumnClick(ByVal ColumnHeader As MSComctlLib.ColumnHeader)
ListView1.Sorted = False
ListView1.SortKey = ColumnHeader.Index - 1

If ListView1.SortOrder = lvwAscending Then
ListView1.SortOrder = lvwDescending
Else
ListView1.SortOrder = lvwAscending
End If

ListView1.Sorted = True
End Sub




But now I get the error

Procedure declaration does not match description of event or procedure having same name

Can somebody give me a clue ?

regards, JOs


--------------= Posted using GrabIt =----------------
------= Binary Usenet downloading made easy =---------
-= Get GrabIt for free from http://www.shemes.com/ =-
 
If you add the ColumnClick event through the VB Editor, you'll find the
definition is

Private Sub ListView1_ColumnClick(ByVal ColumnHeader As Object)

End Sub
 
Back
Top