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

DataBound RadComboBox - deleted value

3 Answers 94 Views
Grid
This is a migrated thread and some comments may be shown as answers.
mSchmidt
Top achievements
Rank 1
mSchmidt asked on 06 Oct 2008, 03:19 PM
Hi

I am using a RadComboBox, which is Bound using the Bind Method, however the value which was originally selected may no longer exist in the ComboBox when it is rebound, this then throws an error.

It there any way to get around this ?


                    <telerik:RadComboBox ZIndex="10000" ID="RadComboBox2" Runat="server"   
                    DataSourceID="Enheder" DataTextField="unit_name" DataValueField="unit_id"   
                    SelectedValue='<%# Bind("ingredient_parcelUnit") %>'   
                    Filter="Contains" MarkFirstMatch="True"  > 
                        <CollapseAnimation Duration="200" Type="OutQuint" /> 
                    </telerik:RadComboBox> 
 

3 Answers, 1 is accepted

Sort by
0
Yavor
Telerik team
answered on 09 Oct 2008, 07:12 AM
Hello mSchmidt,

How and when is the combo databound? How is the data deleted? Is the combo nested in another control? Any additional information will help us better perceive the setup in question, as well as the issue.

Kind regards,
Yavor
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
mSchmidt
Top achievements
Rank 1
answered on 09 Oct 2008, 07:32 AM
Hi

The RadComboBox is located within a FormTemplate of a RadGrid (used when adding/editing values in the grid).
The RadComboBox holds values from another table for instance (tbl_types). A type may be deleted, however the ingredient may not yet have been updated.

Thus when editing the ingredient again the combobox is populated with data however the box may no longer hold the type originally selected when creating the ingredient.

At the moment this results in an error.

0
Yavor
Telerik team
answered on 14 Oct 2008, 06:40 AM
Hi mSchmidt,

The logic for the setup seems correct. However, in order to further investigate the issue, it will be best if you open a formal support ticket, and send us a small project sample, demonstrating the setup.
We will review it locally, and advise you further.

Kind regards,
Yavor
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Grid
Asked by
mSchmidt
Top achievements
Rank 1
Answers by
Yavor
Telerik team
mSchmidt
Top achievements
Rank 1
Share this question
or