4 Answers, 1 is accepted
0
Hello Newgene,
You can attach each RadFilter's ItemCommand event separately and have an if-statement which checks the command name. There are command names for adding and removing expressions:
RadFilter.AddExpressionCommandName
RadFilter.RemoveExpressionCommandName
RadFilter.RemoveGroupCommandName
This way you can execute control-specific logic on the server-side.
Greetings,
Tsvetina
the Telerik team
You can attach each RadFilter's ItemCommand event separately and have an if-statement which checks the command name. There are command names for adding and removing expressions:
RadFilter.AddExpressionCommandName
RadFilter.RemoveExpressionCommandName
RadFilter.RemoveGroupCommandName
This way you can execute control-specific logic on the server-side.
Greetings,
Tsvetina
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
New
Top achievements
Rank 1
answered on 02 Jul 2012, 08:50 AM
Thanks for ur reply Tsvetina,
That i want to check in pre_render
It's Urgent
Thanks Advance ,
New Gene .
That i want to check in pre_render
It's Urgent
Thanks Advance ,
New Gene .
0
Accepted
Hello,
You cannot check this directly in PreRender, but you could use a global variable, assign its value in ItemCommand and check it on PreRender:
All the best,
Tsvetina
the Telerik team
You cannot check this directly in PreRender, but you could use a global variable, assign its value in ItemCommand and check it on PreRender:
string filterId = "";protected void RadFilter1_ItemCommand(object sender, RadFilterCommandEventArgs e){ if (e.CommandName == RadFilter.AddExpressionCommandName || e.CommandName == RadFilter.RemoveExpressionCommandName) { filterId = (sender as RadFilter).ID; }}protected void RadFilter2_ItemCommand(object sender, RadFilterCommandEventArgs e){ if (e.CommandName == RadFilter.AddExpressionCommandName || e.CommandName == RadFilter.RemoveExpressionCommandName) { filterId = (sender as RadFilter).ID; }}protected void Page_PreRender(object sender, EventArgs e){ switch (filterId) { case "RadFilter1": //....... break; case "RadFilter2": //...... break; default: //...... break; }}All the best,
Tsvetina
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
New
Top achievements
Rank 1
answered on 03 Jul 2012, 09:59 AM
Thanks For Ur Help Tsvetina
I'm Dynamically creating Checkbox when i choose the add expression date field, at the time i create the check box,
First time design ins good ,
next time i click some thing design change like that
See The Image ,
Thanks Advance,
New Gene.
I'm Dynamically creating Checkbox when i choose the add expression date field, at the time i create the check box,
First time design ins good ,
next time i click some thing design change like that
See The Image ,
<div style="height: 160px; overflow: auto"> <table> <tr> <td> <telerik:RadFilter runat="server" ID="RadFilter2" FilterContainerID="" ExpressionPreviewPosition="None" ClientSettings-ClientEvents-OnFilterCreated="stopClick" ClientSettings-ClientEvents-OnFilterDestroying="stopClick" EnableViewState="true" Localization-GroupOperationAnd="<%$ Code:Resources.View.View_MeetAny %>" Localization-GroupOperationNotAnd="" Localization-GroupOperationNotOr="" Localization-GroupOperationOr="" Localization-FilterFunctionIsNull="Not Specified" OnPreRender="RadFilter2_PreRender" ShowApplyButton="false" OnFieldEditorCreating="RadFilter2_FieldEditorCreating" OnItemCommand="RadFilter2_ItemCommand" Font-Bold="true"> </telerik:RadFilter> </td> <td> <br /> <br /> <telerik:RadAjaxPanel ID="Panel3" runat="server"> </telerik:RadAjaxPanel> </td> <td> <br /> <br /> <telerik:RadAjaxPanel ID="Panel2" runat="server"> </telerik:RadAjaxPanel> </td> </tr> </table> </div>Thanks Advance,
New Gene.