This is a migrated thread and some comments may be shown as answers.

Preserve entered data inside RadGrid TemplatedForm

1 Answer 33 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Ihab
Top achievements
Rank 1
Ihab asked on 06 Oct 2010, 05:51 AM

Hi,

I have problem RadGrid Templated items as following:

 


As known Telerik provides ability to use templated Edit Form to insert/ edit data, problem we are facing is adding new record from the Grid edit form opened via add new record link that opens the template form, all entered data inside the template controls inside template form will be lost if user pressed any action button such edit button for another record (GridItem) or press again on add new record link that opens the templated form

 

I need to preserve any entered data inside templated control at the runtime regardless to another action being done to the same RadGrid.

 


please refer to this video to view the scenario

http://screencast.com/t/kfIBbdC7EyGm

any help,

1 Answer, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 06 Oct 2010, 02:10 PM
Hello Ihab,

To persist the values that you have entered in the insert form, you can store them as a key value pair with the help of hashtable and store this in a session/viewstate. And when the edit button is clicked check whether the grid is in insert mode or not. If its in insert mode access the controls in insert form and restore the values.
Also refer the following documentation.
Referencing controls in grid row/edit form

Hope this information helps,
Princy.
Tags
Grid
Asked by
Ihab
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Share this question
or