|
-
Jan 3rd, 2004, 02:41 PM
#1
Thread Starter
Hyperactive Member
catch "double click" in datagrid column header cell
Dim pt As Point
Dim hti As DataGrid.HitTestInfo
pt = DataGrid1.PointToClient(Cursor.Position)
hti = DataGrid1.HitTest(pt)
If (hti.Type = DataGrid.HitTestType.ColumnHeader) Then
Messagebox.Show("double clicked")
End If
It says hti.type is 'none'
This code was available on syncfusion.com. I am not able to find out why it says none.
-
Jan 3rd, 2004, 04:56 PM
#2
Frenzied Member
I put the code in the DoubleClick event of datagrid and it works ok. Check it again.
'Heading for the automatic overload'
Marillion, Brave, The Great Escape, 1994
'How will WE stand the FIRE TOMORROW?'
Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979
-
Jan 3rd, 2004, 05:10 PM
#3
Thread Starter
Hyperactive Member
no luck I have put the code in doubleclick event of the datagrid
could you post your code please?
thanks
nath
-
Jan 3rd, 2004, 05:12 PM
#4
Frenzied Member
That's your code I used:
VB Code:
Private Sub DataGrid1_DoubleClick(ByVal sender As Object, ByVal e As System.EventArgs) Handles DataGrid1.DoubleClick
Dim pt As Point
Dim hti As DataGrid.HitTestInfo
pt = DataGrid1.PointToClient(Cursor.Position)
hti = DataGrid1.HitTest(pt)
If (hti.Type = DataGrid.HitTestType.ColumnHeader) Then
MessageBox.Show("double clicked")
End If
End Sub
'Heading for the automatic overload'
Marillion, Brave, The Great Escape, 1994
'How will WE stand the FIRE TOMORROW?'
Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979
-
Jan 3rd, 2004, 06:55 PM
#5
Thread Starter
Hyperactive Member
-
Jan 3rd, 2004, 06:56 PM
#6
Thread Starter
Hyperactive Member
does same code work in asp.net page also
I hope in asmx (web page) same code works.
nath
-
Jan 3rd, 2004, 07:02 PM
#7
Frenzied Member
'Heading for the automatic overload'
Marillion, Brave, The Great Escape, 1994
'How will WE stand the FIRE TOMORROW?'
Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979
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
|