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

How to Remove the Image Button

1 Answer 73 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Mahakar
Top achievements
Rank 1
Mahakar asked on 24 Sep 2008, 02:34 PM
Hi All,

I am using a  asp.net ajax radgrid. I am using filtering with columns in radgrid. I want to remove the image button attached with the filter column.

How can I do this. Please suggest 

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 25 Sep 2008, 04:59 AM
Hi Mahakar,

Try accessing the Filter item in the ItemCreated event and hide it accordingly.

CS:
protected void RadGrid1_ItemCreated(object sender, GridItemEventArgs e) 
    { 
        if (e.Item is GridFilteringItem) 
        { 
            GridFilteringItem filteringItem = (GridFilteringItem)e.Item; 
            Button  btn = filteringItem["ProductName"].Controls[1] as Button; 
            btn.Visible = false
        } 
    } 


Thanks
Shinu
Tags
Grid
Asked by
Mahakar
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or