We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

CurrentCellValidating and CurrentCellMoved events

I have Grid control and foung strange delay between CurrentCellValidating and CurrentCellMoved events. After I leave CurrentcellValidating I have about 2 seconds time delay before I go into CurrentCellMoved. Just do not know what happening in between, debuger does not show anything. I do not handle any other events myself. Thanks, Dargon

8 Replies

AD Administrator Syncfusion Team March 23, 2006 01:24 PM UTC

Hi Dargon, Please refer to this sample, which works fine here. Can you post a small sample showing this problem or tell us how to see it in the Browser sample/Attached sample? If you provide a more information, we will try to debug this issue. Best regards, Madhan.

Grridcellvalidation_GC0.zip


AD Administrator Syncfusion Team March 23, 2006 08:37 PM UTC

It is not easy to provide sample for you. I have GridControl which holds set of syncfusion grids and update all of them. I am looking for the way to see all fired events when user edits grid, may be something happends between Currentcellvalidating and CurrentcellMoved events. Is it any way to see it?I was surprised that debuger did not show me logic flow. Dargon


AD Administrator Syncfusion Team March 24, 2006 06:41 AM UTC

Hi Dragon, Thanks for the information. The time delay may be due to the validating logic in the CurrentCellValidating event. Please refer to this KB article ( What are the different validation events and event members? When are they triggered and how are they used? ) for more details on Validation of a cell. Let us know if you need further information. Best regards, Madhan.


AD Administrator Syncfusion Team March 24, 2006 06:27 PM UTC

Hi Madhan, Thanks for the info. Do you have this article in Word/text format? I do not have OpenOffice installed and can not read .sxw files. I''ll check logic flow on CurrentCellvalidating event, but this time dalay happens AFTER I leave it. I set TraceHelp.WriteFormat("leave ...event" +CurrentTime()) at end of CurrentCellValidating event handling. Another Timing set when debugger enter CurrentCellMoved event. Time difference is about 2 sec. It looks that we Syncfusion Grid does something after validating is done. Am I missing something? Is it possible that we have to finish some processes after Validating is done? Thanks for help, Dargon >Hi Dragon, > >Thanks for the information. The time delay may be due to the validating logic in the CurrentCellValidating event. Please refer to this KB article ( What are the different validation events and event members? When are they triggered and how are they used? ) for more details on Validation of a cell. > >Let us know if you need further information. > >Best regards, >Madhan.


AD Administrator Syncfusion Team March 27, 2006 08:57 AM UTC

Hi Dargon, Sorry for the delayed response. Here is the document in MS word .doc format. We need some clarifications for the following questions. 1. What version of Syncfusion grid and vs.net are you using? 2. What are the other events that you are using? 3. In which event, are the grids getting updated? We have tried our best to reproduce the issue but, could not. It would be better if you could provide us with more details. If possible modify the attached sample, to reproduce the issue. Best regards, Madhan.


AD Administrator Syncfusion Team March 30, 2006 02:31 PM UTC

Hi Madhan, Sorry for delayed feedback, I was buried with another issue... I''ll try to describe here the way the code works: private void followerGrid_CurrentCellValidating (object sender, CancelEventArgs e) { TraceHelp.WriteFormat("***StartTime"+System.DateTime.Now.ToString("dd/mm/yyyy hh:mm:ss.ff")); Do some stuff here... UpdateDatabase(args[]) // this method updates tables in database with value from followerGrid.CurrentCell RefreshGrid()//followerGrid is databound control, so here we need to get updated dataset and bind followergrid to it and Update grid ...Do other stuff... TraceHelp.WriteFormat("endTime+" "+System.DateTime.Now.ToString("dd/mm/yyyy hh:mm:ss.ff")); } //end CurrentCellValidating event private void followerGrid_CurrentCellMoved(object sender, Syncfusion.Windows.Forms.Grid.GridCurrentCellMovedEventArgs e) { TraceHelp.WriteFormat("Checktime"+System.DateTime.Now.ToString("dd/mm/yyyy hh:mm:ss.ff")); Do something... }//end CurrentCellMoved event So I update grid on CurrentcellValidating event. Whet i analyzed timestamps I noticed that difference between EndTime and StartTime is about 2 sec, which is Ok, because we do some slow stuff here. But time difference between EndTime and checkTime is also about 2 sec, however debugger does not show any steps between these 2 events. I found that Refreshgrid() is the method which causes this delay, so it looks that grid gets updated again after Currentcellvalidating event is finished. Debugger does not show it either. Is is something I am missing when trying to update grid on CurrentCellvalidating event? Thanks, Dargon >Hi Dargon, > >Sorry for the delayed response. Here is the document in MS word .doc format. We need some clarifications for the following questions. > >1. What version of Syncfusion grid and vs.net are you using? >2. What are the other events that you are using? >3. In which event, are the grids getting updated? > >We have tried our best to reproduce the issue but, could not. It would be better if you could provide us with more details. If possible modify the attached sample, to reproduce the issue. > >Best regards, >Madhan.


AD Administrator Syncfusion Team March 30, 2006 07:16 PM UTC

Quick update: I think that I foung what''s going on the debugger itself creates this strange delay... Dargon >Hi Madhan, >Sorry for delayed feedback, I was buried with another issue... >I''ll try to describe here the way the code works: > > >private void followerGrid_CurrentCellValidating (object sender, CancelEventArgs e) > { > TraceHelp.WriteFormat("***StartTime"+System.DateTime.Now.ToString("dd/mm/yyyy hh:mm:ss.ff")); > >Do some stuff here... > >UpdateDatabase(args[]) // this method updates tables in database with value from followerGrid.CurrentCell > >RefreshGrid()//followerGrid is databound control, so here we need to get updated dataset and bind followergrid to it and Update grid > >...Do other stuff... > >TraceHelp.WriteFormat("endTime+" "+System.DateTime.Now.ToString("dd/mm/yyyy hh:mm:ss.ff")); >} //end CurrentCellValidating event > > >private void followerGrid_CurrentCellMoved(object sender, Syncfusion.Windows.Forms.Grid.GridCurrentCellMovedEventArgs e) > { > TraceHelp.WriteFormat("Checktime"+System.DateTime.Now.ToString("dd/mm/yyyy hh:mm:ss.ff")); > >Do something... >}//end CurrentCellMoved event > > >So I update grid on CurrentcellValidating event. >Whet i analyzed timestamps I noticed that difference between EndTime and StartTime is about 2 sec, which is Ok, because we do some slow stuff here. But time difference between EndTime and checkTime is also about 2 sec, however debugger does not show any steps between these 2 events. I found that Refreshgrid() is the method which causes this delay, so it looks that grid gets updated again after Currentcellvalidating event is finished. Debugger does not show it either. Is is something I am missing when trying to update grid on CurrentCellvalidating event? >Thanks, >Dargon > > > > >>Hi Dargon, >> >>Sorry for the delayed response. Here is the document in MS word .doc format. We need some clarifications for the following questions. >> >>1. What version of Syncfusion grid and vs.net are you using? >>2. What are the other events that you are using? >>3. In which event, are the grids getting updated? >> >>We have tried our best to reproduce the issue but, could not. It would be better if you could provide us with more details. If possible modify the attached sample, to reproduce the issue. >> >>Best regards, >>Madhan.


AD Administrator Syncfusion Team April 3, 2006 11:17 AM UTC

Hi Dargon, You can may improve the performance by using the CurrentCellAcceptedChanges event to update the database because, it is fired only if the cell has valid changes and there by reducing the time delay to some percent. Best regards, Madhan

Loader.
Live Chat Icon For mobile
Up arrow icon