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
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

GridCointrol edit cell

Thread ID:





12382 Mar 29,2004 02:13 AM UTC Mar 29,2004 10:17 PM UTC WinForms 7
Tags: GridControl
Asked On March 29, 2004 02:13 AM UTC

I have redraw my gridcontrol by dynamic''s dataset.but when i edit the cell of gridcontrol,the form is cloed by itself.i have no code at all. :(

Administrator [Syncfusion]
Replied On March 29, 2004 06:51 AM UTC

Can you post a sample project showing this problem so we can see it here, and try to suggest some way to avoid the problem?

Replied On March 29, 2004 12:50 PM UTC

one form name -----"form1" sub form name -----"form2" form2 have a gridcontrol form1 code: dim tmpForm as new form2 form2.ShowDialog(me) form2 code: at form2_load() Me.GridControl1.BeginUpdate() Me.GridControl1.RowCount = dataTb.Rows.Count Me.GridControl1.ColCount = dataTb.Columns.Count Dim iCol As Integer For iCol = 0 To Me.GridControl1.ColCount - 1 Me.GridControl1(0, iCol + 1).Text = dataTb.Columns(iCol).ColumnName Me.GridControl1.ColWidths(iCol + 1) = dataTb.Columns(iCol).ColumnName.Length * 10 Next Dim i As Integer = 0 While i < dataTb.Rows.Count Dim j As Integer = 0 While j < dataTb.Columns.Count Me.GridControl1(i + 1, j + 1).CellValue = dataTb.Rows(i).Item(dataTb.Columns(j).ColumnName) If j + 1 = dataTb.Columns.Count Then Me.GridControl1(i + 1, j + 1).ReadOnly = False Else Me.GridControl1(i + 1, j + 1).ReadOnly = True End If j = j + 1 End While i = i + 1 End While Me.GridControl1.EndUpdate() Me.GridControl1.Refresh() when i edit the data at the gridcontrol,the form2 will closed by itself. :(

Administrator [Syncfusion]
Replied On March 29, 2004 01:24 PM UTC

Here is a sample that I think does what you described, and I can edit the last column in the grid without the form closing. Forum-2Forms_3451.zip In your case, are there any exceptions being shown in the output window? Are you setting any special tabbing properties when you try to leave the last column? Can you modify the sample to show teh problem?

Replied On March 29, 2004 01:54 PM UTC

error message: Culture "en" is a neutral culture.It can not be used in formatting and parsing and therefore cannot be set as the thread''s current culture.

Administrator [Syncfusion]
Replied On March 29, 2004 03:56 PM UTC

Do you see this problem in the sample I sent you, or in your code? If it is in your code, do you have code that explicitly set some CultureInfo? If so, what is it? Are you using the full 5 character name like "en-US"?

Replied On March 29, 2004 10:07 PM UTC

If i run your project,it is ok. but if i add your form2 into my project and run it,so error message happened. :(

Administrator [Syncfusion]
Replied On March 29, 2004 10:17 PM UTC

Can you attach a project showing the problem? Are you setting CurrentCulture in your code?


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon