The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
Hi,
i have a problem with the TableControlCellClick Event of the GGC. I got a popupMenu opening when the right mouse button is clicked. I also got the current col and rowindex displayed in that popup. Now when I right click cell after cell the indexes don''t get updatet immediately. So all the work i''m performing in that event uses the old cell that i clicked before. How do i refer to the new clicked cell when still the old one is selected and used in the event ?
I already tried the following function: PointToRowCol(new Point(e.Inner.MouseEventArgs.X, e.Inner.MouseEventArgs.Y), out row, out col);
But the same problem here, with a click into the new cell still the one before is used in the event!
ADAdministrator Syncfusion Team April 11, 2005 02:00 PM
If you want the currentcell to move when you right-click, try setting
this.gridGroupingControl1.TableModel.Options.SelectCellsMouseButtonsMask = MouseButtons.Left | MouseButtons.Right;
ADAdministrator Syncfusion Team April 12, 2005 06:36 AM
think I found the problem.
When i use the PointToRowCol Function to determine the underlying Cell, the MouseCoordinates aren''t updated correctly.
If I right-click row1 the TableControlCellMouseUp Event isn''t even triggered. I have to click a 2nd time to get this event fired.
Then the mouse coordinates are in the right place and the right cell gets determined by the PointToRowCol Function. Now, if i move the mouse down the same column to another row and right-click again then the event is fired but the mousecoordinates are still pointing to the old cell. If i click a 2nd time here then the coordinates get updated correctly. Do you have any idea what the problem is ?
ADAdministrator Syncfusion Team April 12, 2005 07:04 PM
Here is a sample that displays a context menu for cell sin a GridGroupingControl. There are two cases. One is a right-click on an inactive cell and the other is a right-click on an active cell. If you do not need this latter support, you do not have to handle the TableControlCurrentCellControlGotFocus and LostFocus.
http://www.syncfusion.com/Support/user/uploads/GGC_BookMark_a879d961.zip