Hello,
I'm trying use domain data source with RadGrid in ASP.NET 4.0 project (by this demo
http://demos.telerik.com/aspnet-ajax/grid/examples/programming/domaindatasource/defaultcs.aspx). I'm using LinqToEntitiesDomainService (EntityFramework).
I'm getting following error:
Server Error in '/' Application.
The method 'Skip' is only supported for sorted input in LINQ to Entities.
The method 'OrderBy' must be called before the method 'Skip'.
Description:
An unhandled exception occurred during the execution of the current web
request. Please review the stack trace for more information about the error and
where it originated in the code.
Exception Details:
System.NotSupportedException: The method 'Skip' is only supported for sorted
input in LINQ to Entities. The method 'OrderBy' must be called before the method
'Skip'.
Source Error:
An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.
|
Stack Trace:
[NotSupportedException: The method 'Skip' is only supported for sorted input in LINQ to Entities. The method 'OrderBy' must be called before the method 'Skip'.]
System.Data.Objects.ELinq.PassthroughOrderByLifter.Skip(DbExpression k) +94
System.Data.Objects.ELinq.ExpressionConverter.Skip(DbExpressionBinding input, DbExpression skipCount) +31
System.Data.Objects.ELinq.SkipTranslator.TranslatePagingOperator(ExpressionConverter parent, DbExpression operand, DbExpression count) +63
System.Data.Objects.ELinq.PagingTranslator.TranslateUnary(ExpressionConverter parent, DbExpression operand, MethodCallExpression call) +62
System.Data.Objects.ELinq.UnarySequenceMethodTranslator.Translate(ExpressionConverter parent, MethodCallExpression call) +81
System.Data.Objects.ELinq.SequenceMethodTranslator.Translate(ExpressionConverter parent, MethodCallExpression call, SequenceMethod sequenceMethod) +14
System.Data.Objects.ELinq.MethodCallTranslator.TypedTranslate(ExpressionConverter parent, MethodCallExpression linq) +102
System.Data.Objects.ELinq.TypedTranslator`1.Translate(ExpressionConverter parent, Expression linq) +54
System.Data.Objects.ELinq.ExpressionConverter.TranslateExpression(Expression linq) +110
System.Data.Objects.ELinq.UnarySequenceMethodTranslator.Translate(ExpressionConverter parent, MethodCallExpression call) +58
System.Data.Objects.ELinq.SequenceMethodTranslator.Translate(ExpressionConverter parent, MethodCallExpression call, SequenceMethod sequenceMethod) +14
System.Data.Objects.ELinq.MethodCallTranslator.TypedTranslate(ExpressionConverter parent, MethodCallExpression linq) +102
System.Data.Objects.ELinq.TypedTranslator`1.Translate(ExpressionConverter parent, Expression linq) +54
System.Data.Objects.ELinq.ExpressionConverter.TranslateExpression(Expression linq) +110
System.Data.Objects.ELinq.ExpressionConverter.Convert() +16
System.Data.Objects.ELinq.ELinqQueryState.GetExecutionPlan(Nullable`1 forMergeOption) +110
System.Data.Objects.ObjectQuery`1.GetResults(Nullable`1 forMergeOption) +149
System.Data.Objects.ObjectQuery`1.System.Collections.Generic.IEnumerable<T>.GetEnumerator() +44
System.Data.Objects.ObjectQuery`1.GetEnumeratorInternal() +36
System.Data.Objects.ObjectQuery.System.Collections.IEnumerable.GetEnumerator() +10
System.ServiceModel.DomainServices.Server.DomainService.Enumerate(IEnumerable enumerable, Int32 estimatedResultCount) +299
System.ServiceModel.DomainServices.Server.DomainService.Query(QueryDescription queryDescription, IEnumerable`1& validationErrors, Int32& totalCount) +1289
Microsoft.Web.UI.WebControls.DomainDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments) +435
System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +21
System.Web.UI.WebControls.DataBoundControl.PerformSelect() +143
Telerik.Web.UI.GridTableView.PerformSelect() +16
System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +74
Telerik.Web.UI.GridTableView.DataBind() +259
Telerik.Web.UI.RadGrid.DataBind() +87
System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() +66
System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls() +75
System.Web.UI.Control.EnsureChildControls() +102
Telerik.Web.UI.GridBaseDataList.get_Controls() +15
Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +41
Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +623
Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +623
Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +623
Telerik.Web.UI.RadFormDecorator.FindAndDecorateControls(Control parent) +623
Telerik.Web.UI.RadFormDecorator.DecorateAspNetControls() +39
Telerik.Web.UI.RadFormDecorator.ControlPreRender() +624
Telerik.Web.UI.RadWebControl.OnPreRender(EventArgs e) +22
System.Web.UI.Control.PreRenderRecursiveInternal() +103
System.Web.UI.Control.PreRenderRecursiveInternal() +175
System.Web.UI.Control.PreRenderRecursiveInternal() +175
System.Web.UI.Control.PreRenderRecursiveInternal() +175
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2496
|
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET
Version:4.0.30319.237
Could you help me please?
Thank you