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

Google like filtering on details table rad grid

1 Answer 72 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Balamurali Venkatesan
Top achievements
Rank 1
Balamurali Venkatesan asked on 10 Oct 2008, 04:35 PM
Hi,

Could you please lete me know how to implement the Google like filtering in the Hierachy Grid.

Iam able to create the custom column derived from the GrodBoundColumn and able to set the Google like filters.

Iam setting the datasource for the RadCombo in the RAdGRid_Colun Cretaing event as follows

protected

void radGridProducts_ColumnCreating(object sender, GridColumnCreatingEventArgs e)

 

{

 

if (e.ColumnType == typeof(GoogleFilterColumn).Name)

 

{

e.Column =

new GoogleFilterColumn();

 

 

int dbId = (int)HttpContext.Current.Session["INSTR_ID"];

 

(e.Column

as GoogleFilterColumn).ListDataSource = GetDataTable(query);

 

}}

As you all know the mastertable would have a dataset ..and the detial table would have its own dataset.

The ColumnCreating event doesn't have any event to identify if its a Mastertable or Detailtable.So even for the Detailtable google filter Iam getting the same list of avlues that was created for the Mastertable as the query is same.

when i clcik the google filter in the detailtable i should have a way to pass a differnt query to fetch the results based on that level

1 Answer, 1 is accepted

Sort by
0
Sebastian
Telerik team
answered on 14 Oct 2008, 09:58 AM
Hello Balamurali,

You can use the e.OwnerTableView.Name property inside the ColumnCreating event to identify to which level in the hierarchy the custom column which is about to be created belongs.

Review the DetailTableDataBind handler in this online demo which illustrates how to check the value of this property in a hierarchical grid:

http://demos.telerik.com/ASPNET/Prometheus/Grid/Examples/Programming/DetailTableDataBind/DefaultCS.aspx

Best regards,
Stephen
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Grid
Asked by
Balamurali Venkatesan
Top achievements
Rank 1
Answers by
Sebastian
Telerik team
Share this question
or