Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
6509 | Aug 14,2003 03:15 PM UTC | Aug 14,2003 08:17 PM UTC | WinForms | 3 |
![]() |
Tags: GridControl |
'VBPrivate Sub gridControl1_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles Sub gridControl1.MouseDown If e.Button = MouseButtons.Right Then dim rowIndex, colIndex as Integer Me.gridControl1.PointToRowCol(New Point(e.X, e.Y), rowIndex, colIndex) Console.WriteLine(rowIndex.ToString() + " " + colIndex.ToString()) End If End Sub //C# private void gridControl1_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e) { if(e.Button == MouseButtons.Right) { int row, col; if(this.gridControl1.PointToRowCol(new Point(e.X, e.Y), out row, out col, -1)) { Console.WriteLine(row.ToString() + " " + col.ToString()) } } }
This post will be permanently deleted. Are you sure you want to continue?
Sorry, An error occured while processing your request. Please try again later.
This page will automatically be redirected to the sign-in page in 10 seconds.