clear Radfilter expression

2 posts, 0 answers
  1. rik butcher
    rik butcher avatar
    106 posts
    Member since:
    Jul 2009

    Posted 04 May 2012 Link to this post

    ive got a function in the code behind that automatically adds an expression on a tab click on a mutli page.
    but clicking back a tab simply creates another one.
    how can i clear it FIRST AND THEN add the expression. i was hoping the RecreateControl would work

     

     

    protected void showfilterTabs(int tab)

     

    {

     

     

    if (tab == 0)

     

    {

     

     

    RadFilterStartsWithFilterExpression expr1 = new RadFilterStartsWithFilterExpression("WORKORDERNUMBER");

     

    expr1.Value =

     

    "";

     

    WorkOrdersRadFilter.RootGroup.AddExpression(expr1);

    WorkOrdersRadFilter.RecreateControl();

    }

     

     

    else if (tab == 1)

     

    {

     

     

    RadFilterStartsWithFilterExpression expr1 = new RadFilterStartsWithFilterExpression("WORKORDERNUMBER");

     

    expr1.Value =

     

    "";

     

    WorkOrderItemsRadFilter.RootGroup.AddExpression(expr1);

    WorkOrderItemsRadFilter.RecreateControl();

    }

     

     

    else if (tab == 2)

     

    {

     

     

    RadFilterStartsWithFilterExpression expr1 = new RadFilterStartsWithFilterExpression("WORKORDERNUMBER");

     

    expr1.Value =

     

    "";

     

    SearchAllOrdersRadFilter.RootGroup.AddExpression(expr1);

    SearchAllOrdersRadFilter.RecreateControl();

    }

     

     

    else if (tab == 3)

     

    {

     

     

    RadFilterStartsWithFilterExpression expr1 = new RadFilterStartsWithFilterExpression("WORKORDERNUMBER");

     

    expr1.Value =

     

    "";

     

    StorageWorkOrdersRadFilter.RootGroup.AddExpression(expr1);

    StorageWorkOrdersRadFilter.RecreateControl();

    }

     

     

    else if (tab == 4)

     

    {

     

     

    RadFilterStartsWithFilterExpression expr1 = new RadFilterStartsWithFilterExpression("WORKORDERNUMBER");

     

    expr1.Value =

     

    "";

     

    SearchAllItemsRadFilter.RootGroup.AddExpression(expr1);

    SearchAllItemsRadFilter.RecreateControl();

    }

     

     

    else if (tab == 5)

     

    {

     

     

    RadFilterStartsWithFilterExpression expr1 = new RadFilterStartsWithFilterExpression("WORKORDERITEMDISPLAY");

     

    expr1.Value =

     

    "";

     

    InventoriesRadFilter.RootGroup.AddExpression(expr1);

    InventoriesRadFilter.RecreateControl();

    }

    }

  2. rik butcher
    rik butcher avatar
    106 posts
    Member since:
    Jul 2009

    Posted 04 May 2012 Link to this post

    never mind. my bad found the Clear Function
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top