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

[Solved] "Google-like" Filtering in Dynamically Created Grid Inside Nested View

2 Answers 84 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Manuel Ortiz
Top achievements
Rank 1
Manuel Ortiz asked on 24 Sep 2009, 02:40 AM
Hello,

I have a radgrid that has a NestedView Template.  Inside that template I have a Placeholder which will be populated by a dynamically created control like a textbox or another radgrid, depending on some logic I have server side.  I would like to have Google-Like filtering in the nested grid, however I don't know how to do it since I don't have a declarative ID for the nested grid that I can use to reference it inside the javascript method needed for such filtering to work.  This is because, in addition that it is programatically created, the grid is also in the nested view of each item (or row) so it does not have an unique ID as would a declaratively declared control would have.

So, is there anyway I can reference such grid from the javascript method that is used in your examples of the Google-Like filtering, in order for such filtering to work on my nested grid?

Any help would be greatly appreciated,
Manuel

2 Answers, 1 is accepted

Sort by
0
Manuel Ortiz
Top achievements
Rank 1
answered on 26 Sep 2009, 07:01 AM
Hello,

I am still having this problem, any ideas please??

-Manuel
0
Sebastian
Telerik team
answered on 29 Sep 2009, 01:43 PM
Hello Manuel,

How to access server controls in grid templates on the client you can see from this code library project:
http://www.telerik.com/community/code-library/aspnet-ajax/grid/accessing-server-controls-in-a-grid-template-on-the-client.aspx

The difference when having another grid instance inside the NestedViewTemplate of the parent grid would be that you need to use the $find(gridId) method to reference the client object of the embedded grid (instead of $get(gridId) which will return its DOM element). After that you can operate with the client grid object in the same manner as you will do when the control is directly on the page.

Kind regards,
Sebastian
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.
Tags
Grid
Asked by
Manuel Ortiz
Top achievements
Rank 1
Answers by
Manuel Ortiz
Top achievements
Rank 1
Sebastian
Telerik team
Share this question
or