Hi,
I am trying to create my own filter template for a certain column in RadGrid dynamically. I tried to do this on Load/Render/init, still to no avail.
myColumn.FilterTemplate = new CustomGridTemplate();
...
public class CustomGridTemplate: ITemplate
{
public CustomGridTemplate()
{
}
public void InstantiateIn(System.Web.UI.Control container)
{
TextBox tbx = new TextBox();
tbx.Text = "Test";
container.Controls.Add(tbx);
}
}
The grid filter shows up with the standard controls for that column - the breakpoint in CustomGridTemplate class constructor doesn't even get hit. I've seen an example for regular templated columns, but I am using AutoGeneratedColumns. I would appreciate your comments.
I am trying to create my own filter template for a certain column in RadGrid dynamically. I tried to do this on Load/Render/init, still to no avail.
myColumn.FilterTemplate = new CustomGridTemplate();
...
public class CustomGridTemplate: ITemplate
{
public CustomGridTemplate()
{
}
public void InstantiateIn(System.Web.UI.Control container)
{
TextBox tbx = new TextBox();
tbx.Text = "Test";
container.Controls.Add(tbx);
}
}
The grid filter shows up with the standard controls for that column - the breakpoint in CustomGridTemplate class constructor doesn't even get hit. I've seen an example for regular templated columns, but I am using AutoGeneratedColumns. I would appreciate your comments.