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
close icon

Issue with AddNewRecord and DateTime

Hi,

I''m having an issue with the AddNewRecord and datetime objects.

Refering to the attached sample application (built in vs 2k5 grid version 4.202.0.60)

I''m getting an error when entering a date, then deleting the date and then trying to enter a new value.

Below are the steps I take to reproduce the error
1)Enter a valid date into the DateCol
2)Tab out of the column
3)shift tab back into the DateCol
4)clear the value (esc or delete)
5)tab into the OtherColumn
6)enter a value

Any values you enter into any of the rows will be invalid and have an error of "There is no row at position 0."

Is this a known issue and is there a workaround for this?

Another issue that we''re having is when the current focus is on the first row/col cell and you alt tab out of the application then alt tab back in you are unable to type into that cell. (it seems as though the event to initiate the ContextChange event to start the editing is not firing)

If you can get back to me ASAP that''d be great.

Paulo

WindowsApplication218.zip

3 Replies

AD Administrator Syncfusion Team October 5, 2006 11:26 AM UTC

Hi Paulo,

Thanks for being patience. We are currently working on this issue, which we will update the details soon.

Best regards,
Haneef


AD Administrator Syncfusion Team October 5, 2006 12:17 PM UTC

Hi Paulo,

You can handle the TableControlCurrentCellKeyDown and set CurrentCell.IsModified property to TRUE. Below is a code snippet

private void grid_TableControlCurrentCellKeyDown(object sender, Syncfusion.Windows.Forms.Grid.Grouping.GridTableControlKeyEventArgs e)
{
GridCurrentCell cc = e.TableControl.CurrentCell;
GridTableCellStyleInfo style = cc.Renderer.CurrentStyle as GridTableCellStyleInfo;
if (style.TableCellIdentity.DisplayElement.Kind == DisplayElementKind.AddNewRecord)
cc.IsModified = true;
}

Thanks,
Haneef


PC Paulo Cristini October 5, 2006 02:56 PM UTC

Which issue is this supposed to assist in resolving? It does not appear to help with either of them.

Thanks,
Paulo

Loader.
Live Chat Icon For mobile
Up arrow icon