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

Related Combos in Grid: How to Update?

1 Answer 48 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Peter O'Connor
Top achievements
Rank 1
Peter O'Connor asked on 05 Sep 2012, 12:30 PM
I have a radgrid with AllowAutomaticInserts ="True" and AllowAutomaticUpdates="True" and EditMode ="EditForms".  This grid is bound to a telerik:OpenAccessLinqDataSource.  Everything works fine, records are displayed, and user can edit and insert records.
 
Now I have this same scenario, but I need one of the combos in the grid to be populated according to the selected item in another combo in the same grid (during insert or update).  This I have done and works fine (using OnSelectedIndexChanged), but the value in the freshly populated combo is not automatically picked up by the grid during inserting or updating.
 
I have seen examples using code behind to save the record but my quesion is this:
 
I like the automatic display and save of the radgrid using automaticupdates and automaticinserts with virtually no code behind.  Is it possible to keep this model and still have the related combo's in some way (i.e. to get the saving of records without resorting to much or any code behind)?
 
Thanx

1 Answer, 1 is accepted

Sort by
0
Kostadin
Telerik team
answered on 10 Sep 2012, 10:36 AM
Hello Peter,

You could populate the combo by using JavaScript. Please check out this demo where it is demonstrated how you could do that. Also you could take a look at the Related Resources tab for more information.

All the best,
Kostadin
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Grid
Asked by
Peter O'Connor
Top achievements
Rank 1
Answers by
Kostadin
Telerik team
Share this question
or