Hi
at your example http://demos.telerik.com/aspnet-ajax/grid/examples/performance/linq/defaultcs.aspx in here
when you filter objects always the page count is 300 000
how can this be updated when user filters the data
4 Answers, 1 is accepted
0
hedere
Top achievements
Rank 1
answered on 25 Oct 2009, 04:19 PM
i need a problem for this situation
can you pls help me about this
can you pls help me about this
0
Hi hedere,
The number comes from the following code snippet:
void LinqDataSource1_Selecting(object sender, LinqDataSourceSelectEventArgs e)
{
e.Arguments.TotalRowCount = 300000;
if (CheckBox3.Checked)
{
if (Cache["MyData"] != null)
{
e.Result = Cache["MyData"];
}
}
retrieveWatch.Reset();
retrieveWatch.Start();
}
You can alter the 300000 number accordingly, to eliminate this behavior.
I hope this information helps.
Kind regards,
Yavor
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
The number comes from the following code snippet:
void LinqDataSource1_Selecting(object sender, LinqDataSourceSelectEventArgs e)
{
e.Arguments.TotalRowCount = 300000;
if (CheckBox3.Checked)
{
if (Cache["MyData"] != null)
{
e.Result = Cache["MyData"];
}
}
retrieveWatch.Reset();
retrieveWatch.Start();
}
You can alter the 300000 number accordingly, to eliminate this behavior.
I hope this information helps.
Kind regards,
Yavor
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
hedere
Top achievements
Rank 1
answered on 26 Oct 2009, 09:43 PM
Yavor thanks for your reply
i tried to set the number with query.count() propery but
e.Arguments.TotalRowCount = query.count();
it always takes the count of total date returned from the linqdatasource how can i achive that the filtered data count from the radGrid?
Is there a way to take filtered data count from radGrid?
0
Hi hedere,
The other options are to either determine manually how many items are returned from the datasource, for example by re-querying the datasource with the filter expression. Or, you can set the AutoPage property for the LinqDataSource to true, so that the linq datasource can automatically determine the number of items it retrieves.
I hope this information helps.
Kind regards,
Yavor
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
The other options are to either determine manually how many items are returned from the datasource, for example by re-querying the datasource with the filter expression. Or, you can set the AutoPage property for the LinqDataSource to true, so that the linq datasource can automatically determine the number of items it retrieves.
I hope this information helps.
Kind regards,
Yavor
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.