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

Few Queries related with Edit functionality

Thread ID:

Created:

Updated:

Platform:

Replies:

19151 Sep 20,2004 07:20 AM Sep 21,2004 06:11 AM Windows Forms 5
loading
Tags: GridControl
Thiyagu
Asked On September 20, 2004 07:20 AM

Hi Clay, I''m using a GDBG grid. This grid is initially in Readonly mode. When the user clicks on edit button after selecting a particular row, then that selected row will become editable. I was able to make the grid Readonly and the selected row editable, but when the user leaves the curren row and comes back to the same row, that row is turning back to Readonly mode. How do I retain the row in the Edit mode until the User Commits the Changes he made. And the second thing, I''m having a Checkbox column bounded to a Database field in the Grid. But I couldn''t enable that Column when the User clicks on Edit. The user was unable to Check/Uncheck the Column. Please help me out in solving these problems. Thanks, Thiagu.

Stefan Hoenig
Replied On September 20, 2004 08:40 AM

Hi Thiagu, you need to provide some storage where you can specify which rows should be editable and which not. This could be a field in your DataRow or it could be Hashtable. You could then handle QueryCellInfo and set e.Style.ReadOnly = false for those rows that have been marked readonly and e.Style.ReadOnly = true otherwise. That should also work with the CheckBoxes. If for some reason ReadOnly settings are cached internally try calling also Model.ResetVolatileData(). This will ensure that QueryCellInfo gets triggered again adn then you should be able to click on the checkbox. Stefan

Thiyagu
Replied On September 20, 2004 09:00 AM

Hi Stefan, It will be of great help for me if you can send me some sample code. Thanx in advance, Thiagu. >Hi Thiagu, > >you need to provide some storage where you can specify which rows should be editable and which not. > >This could be a field in your DataRow or it could be Hashtable. > >You could then handle QueryCellInfo and set e.Style.ReadOnly = false for those rows that have been marked readonly and e.Style.ReadOnly = true otherwise. > >That should also work with the CheckBoxes. If for some reason ReadOnly settings are cached internally try calling also Model.ResetVolatileData(). This will ensure that QueryCellInfo gets triggered again adn then you should be able to click on the checkbox. > >Stefan >

Administrator [Syncfusion]
Replied On September 20, 2004 09:51 AM

Attached find an example. Stefan ToogleRowEditState_9495.zip

Thiyagu
Replied On September 21, 2004 02:59 AM

Stefan, Seems some problem in the application you ''ve send. It''s not fetching the data and not allow me to edit the row which is empty. Thiagu. >Attached find an example. > >Stefan > >ToogleRowEditState_9495.zip > >

Administrator [Syncfusion]
Replied On September 21, 2004 06:11 AM

Just set useMSDE = true or make place the sample under the Grid\Samples folder so that it can pick up the Xml file from the Suite\Data folder. Regarding the last row, you can compare e.RowIndex == Model.RowCount and then set the ReadOnly setting appropriately in QueryCellInfo. Stefan

CONFIRMATION

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.

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.

;