This question is locked. New answers and comments are not allowed.
I use RadGrid with OpenAccessDataSource
Here is the definition of OpenAccessDataSource:
Here is the definition of OpenAccessDataSource:
| <telerik:OpenAccessDataSource ID="DialogScriptDataSource" runat="server" |
| EnableDelete="True" EnableInsert="True" EnableUpdate="True" |
| ObjectContextProvider="EAGG.ORM.ObjectScopeProvider1, EAGG.ORM" |
| TypeName="EAGG.ORM.DialogAction" Where="DialogID = @DialogID" |
| oninserting="DialogScriptDataSource_Inserting" ContextTypeName="" |
| OrderBy="DialogActionOrder" onupdating="DialogScriptDataSource_Updating"> |
| <WhereParameters> |
| <asp:QueryStringParameter DbType="Int32" Name="DialogID" |
| QueryStringField="Id" /> |
| </WhereParameters> |
| </telerik:OpenAccessDataSource> |
Then i use the open access data source as the RadGrid DataSource. The RadGrid is using EditTemplate for editing. If there are records from WhereParameter result, i could do edd, insert, delete to the RadGrid. However, if the return result of the OpenAccessDataSource is nothing, when i click add new record, i got this error message :
DataBinding: 'Telerik.Web.UI.GridInsertionObject' does not contain a property with the name 'DialogActionTypeID'.
I know you could bind default values for case like this, however this behaviour doesn't happen to OjectDataSource or SqlDataSource, plus i don't want to predefine all the values for insert.
Is this the designed behaviour of OpenAccessDataSource or did i do something wrong?
jaimie