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

CheckBoxColumn and Entity Data Source

1 Answer 50 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jochen
Top achievements
Rank 2
Jochen asked on 09 Oct 2014, 12:57 PM
Hi,

what ist the best practice to bind the CheckboxColumn to a non boolean column / property (we have a legacy database that uses smallint instead - like null or 0 for false and 1 for true)? I tried it with a partial class with wrapper properties on entity Level, but then ran into errors when inserting / updateing / editing within RadGrid


Exception = {"A property named 'BSPERRUNG' was not found on the entity during an insert, update, or delete operation. Check to ensure that properties specified as binding expressions are available to the data source."}

BSPERRUNG is the wrapper property for SPERRUNG, that is the original smallint column.

Are there any possibilities to achieve this with built in RadGridView features?

Greets Jochen

1 Answer, 1 is accepted

Sort by
0
Marin
Telerik team
answered on 13 Oct 2014, 01:18 PM
Hello,

Basically in order for the wrapper class approach to work you need to bind the control to objects of this new wrapper type so that it knows how to work with the BSPERRUNG field instead of SPERRUNG. You can also check whether the new partial BUCHKTAB class is correctly picked up by the entity framework and it detects the new properties as members of the entity.

I have also replied with further details in the support ticket you have opened on the same issue. So you can also try the approach with grid events mentioned there if the wrapper of the entity class is causing too much trouble.

Regards,
Marin
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Grid
Asked by
Jochen
Top achievements
Rank 2
Answers by
Marin
Telerik team
Share this question
or