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

Pass extra parameters to PageMethods.GetData

2 Answers 280 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Bieters Bieters
Top achievements
Rank 1
Bieters Bieters asked on 13 Dec 2010, 03:31 PM
Hello,
I'm trying to populate the radgrid on the client side using this demo:
http://demos.telerik.com/aspnet-ajax/grid/examples/client/databinding/defaultcs.aspx

In the demo, there is this call:
PageMethods.GetData(0, tableView.get_pageSize(),
                tableView.get_sortExpressions().toString(), tableView.get_filterExpressions().toList(),
                    updateGrid);


Is it possible to pass extra parameters to the GetData server method?

Thanks.

2 Answers, 1 is accepted

Sort by
0
Bieters Bieters
Top achievements
Rank 1
answered on 14 Dec 2010, 07:48 AM
What I'm trying to do is specify an argument for retrieval of the datasource for the grid.
I want to pass this argument via javascript to the server.
Thanks.
0
Nikolay Rusev
Telerik team
answered on 14 Dec 2010, 10:43 AM
Hello Bieters,

Of course you can pass extra parameters. Calling page method on client should match the number of params in the page method declaration. For example if you add extra params when calling PageMethods.GetData... in code-behind of the page GetData static method should have this extra params in its signature.

Regards,
Nikolay
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Tags
Grid
Asked by
Bieters Bieters
Top achievements
Rank 1
Answers by
Bieters Bieters
Top achievements
Rank 1
Nikolay Rusev
Telerik team
Share this question
or