Conditional Formatting Rules

3 posts, 0 answers
  1. cheekl
    cheekl avatar
    55 posts
    Member since:
    Jul 2012

    Posted 12 Jul 2011 Link to this post

    Hi,
    I created a conditional formatting rules for subreport
    where
    expression = Fields.Item1
    Operator = In
    Value = 1,2,3
    style.visisble = false

    But the subreport still visible. If i create multiple rules using operator "=" then it works.
    How can I use operator "In"?



  2. Peter
    Admin
    Peter avatar
    1611 posts

    Posted 12 Jul 2011 Link to this post

    Hi Cheekl,

    The IN operator requires an object array but the expression engine doesn't supports syntax for specifying object array. However you can use an user function to convert a comma separated string value to an object[] as shown in the following code snippet and sample value expression:

    public static object[] ConvertStringArray(string value)
    {
        return value.Split(',');
    }

    = ConvertStringArray("1,2,3") 

    All the best,
    Peter
    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

  3. DevCraft banner
  4. cheekl
    cheekl avatar
    55 posts
    Member since:
    Jul 2012

    Posted 13 Jul 2011 Link to this post

    Hi Peter,
    Thanks for your help. It works.
Back to Top