AAArulraj A Syncfusion Team February 18, 2019 04:58 AM
Thanks for using Syncfusion product.
We tried to reproduce the issue at our end with different combinations of PasteOptions and AllowPasteOptionPopup. However, we were unable to reproduce the issue. So, please provide us the below details that will helpful for us to provide a better solution.
Call Stack and exception details of the issue.
The code that causes the reported scenario at your end.
Also refer the attached sample and let us know the changes from the issue reproduced sample.
Please let us know if you have any other concerns.
SPSpottyFebruary 19, 2019 06:06 PM
I'm doing multiple cut/copy paste actions and it does not occur with regular frequency. ie, I can do it once and it will fail and the next time it will succeed.
Call stacks that occur when it happens are:
System.InvalidOperationException: BeginTransaction without CommitTransaction
at Syncfusion.Windows.Forms.Spreadsheet.History.HistoryManager.BeginTransaction(String s)
at Syncfusion.Windows.Forms.Spreadsheet.SpreadsheetCopyPaste.Paste(GridRangeInfoList range, PasteOptions e)
at Syncfusion.Windows.Forms.Spreadsheet.SpreadsheetCopyPaste.Paste(GridRangeInfoList range)
at Syncfusion.Windows.Forms.CellGrid.SelectionController.HandleKeyDown(KeyEventArgs args)
at Syncfusion.Windows.Forms.Spreadsheet.SpreadsheetGrid.ProcessKeyEventArgs(Message& m)
at System.Windows.Forms.Control.ProcessKeyMessage(Message& m)
at System.Windows.Forms.Control.WmKeyChar(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at Syncfusion.Windows.Forms.ScrollControl.WndProc(Message& msg)
at Syncfusion.Windows.Forms.Spreadsheet.SpreadsheetGrid.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
If this helps. I will endeavor to continue to get call stacks when it does occur and confirm that it is always occurring at the same point.
MGMohanraj Gunasekaran Syncfusion Team February 20, 2019 08:54 AM
Thanks for using Syncfusion product.
We have tried the cut/copy paste option using below attached sample in our latest Syncfusion product version 18.104.22.168. But the sample is working fine as we expected. Please let us know the exact use case to reproduce your reported scenario and let us know the below attached sample differ from your customization. It will be helpful us to investigate further.
As I stated the repro is not a stable repro and occurs periodically when testing my applications which is doing a lot of cut/copy/paste activities enough that it has become noticeable and was tracked when I was videoing a walkthrough of the application. I can provide a repro project. This is material that I would not like to be made publicly available but would like to fix the problem.
This code is the code on other cut/copy paste problems that have been encountered and your having problems reproing.
As for the code - the cut/copy/paste actions have not user code. These are merely taking cells in the spreadsheet and acting upon them using the default spreadsheet implementations so there is absolutely none of my code involved in the cut/copy paste functionality. It case occured using either the context menu or Ctrl C,X and V shortcuts.
AAArulraj A Syncfusion Team February 22, 2019 11:42 AM
I believe I may have a reliable repro for this error which I'll send PM with repro steps.
AAArulraj A Syncfusion Team March 29, 2019 08:34 AM
Thanks for the update.
We are able to reproduce the reported problem, we have sent this to our development team to validate and we will update you the details on 2 April 2019.
We appreciate your patience until then.
DYDeivaselvan Y Syncfusion Team April 2, 2019 07:17 AM
Thank you for your patience.
You can resolve the reported issue by handling the below highlighted code in CustomRenderer.cs fileon your application. Kindly try with this and let us know if this helps you.
Protected Overrides Sub OnEditElementLostFocus(sender As Object, e As EventArgs)
'To commit the cell value.
If Me.Grid.CurrentCell.IsModified Then
SPSpottyApril 2, 2019 08:53 AM
Yes i put this in at your advice to deal with another issue which then resulted in consistent repro of same error. I suspect that thwre are still ways to generate this error without this code in place.
DYDeivaselvan Y Syncfusion Team April 3, 2019 05:51 AM
Thanks for your update.
We have tested your reported scenario in your provided sample with our suggested changes. There is no exception occurred as you reported. The sample is working fine as we expected. Here, we have attached our tested video demo. Please let us know, if we have missed anything from your test cases. It will be helpful us to investigate further.