none
Hide plus sign if it contains only one record in ssrs (toggle)

    Question

  • Hi,

    I have created a ssrs report which also contain toggle settings.

    Now my question is to remove plus sign if recordset contain single record.

    Please help to solve this issue.

    Thanks in advance!

    Regards

    Rajni

    Wednesday, April 03, 2013 7:56 AM

Answers

  • Hi Rajni,

    We can add a column in the left side of the parent group, and set the child group can be toggle by this new inserted column. And use the expression below:
    =iif(runningvalue(Fields!childegroup.Value,count,"ParentGroup")=1,true,false)
    And when add a group add a group header, and use the expression below in the group header:
    =iif(runningvalue(Fields!childegroup.Value,count,"ParentGroup")=1,Fields!Subcategory.Value,"")

    The screenshots below are for your reference.

    If you have any questions, please feel free to ask.

    Regards,


    Charlie Liao
    TechNet Community Support

    • Marked as answer by Rajni Kaushal Thursday, April 04, 2013 8:51 AM
    Thursday, April 04, 2013 4:25 AM
  • Hi Charlie,

    Thanks for the suggestion. I have solved this issue with your hint.

    I have do it by following:

    Added one column on the left like given above.

    Then click on first column-> textbox properties -> visibility -> Show or hide based on expression and added following expression in it : 

    =iif(count(Fields!Title.Value)=1,true,false)

    Now i have added expression on the above column of subcategory as given in the above image and expression is:

    =iif(count(Fields!Title.Value)=1,Fields!Title.Value,"")

    By doing this i have solved my issue.

    Thanks all for the kind support.

    Regards

    Rajni

    

    • Marked as answer by Rajni Kaushal Thursday, April 04, 2013 8:52 AM
    Thursday, April 04, 2013 8:51 AM

All replies

  • I don't believe you can do that unfortunately, as far as i know it is not supported to show a collapse icon for some items and not others. 

    It is either on, or off.


    Thanks! Josh

    Thursday, April 04, 2013 1:14 AM
  • Hi Rajni,

    We can add a column in the left side of the parent group, and set the child group can be toggle by this new inserted column. And use the expression below:
    =iif(runningvalue(Fields!childegroup.Value,count,"ParentGroup")=1,true,false)
    And when add a group add a group header, and use the expression below in the group header:
    =iif(runningvalue(Fields!childegroup.Value,count,"ParentGroup")=1,Fields!Subcategory.Value,"")

    The screenshots below are for your reference.

    If you have any questions, please feel free to ask.

    Regards,


    Charlie Liao
    TechNet Community Support

    • Marked as answer by Rajni Kaushal Thursday, April 04, 2013 8:51 AM
    Thursday, April 04, 2013 4:25 AM
  • Well that is a handy cheat, but it will get very messy if you have toggle items on anything but the highest level as a separate column will be required at each child level.. 

    For example, if it was three levels we then need another column between Category1 and Subcategory to hide level 3, and so on. 


    Thanks! Josh

    Thursday, April 04, 2013 4:36 AM
  • Hi Charlie, 

    Could you explain it in detail.

    Actually i am new in ssrs. PLease provide me its detail like how to add child group etc.

    Thanks 

    Rajni

    Thursday, April 04, 2013 5:19 AM
  • Hi,

    I have tried it Charlie but its giving me error.

    Please help to solve this issue.

    Thanks

    Rajni

    Thursday, April 04, 2013 5:30 AM
  • Hi Charlie,

    Thanks for the suggestion. I have solved this issue with your hint.

    I have do it by following:

    Added one column on the left like given above.

    Then click on first column-> textbox properties -> visibility -> Show or hide based on expression and added following expression in it : 

    =iif(count(Fields!Title.Value)=1,true,false)

    Now i have added expression on the above column of subcategory as given in the above image and expression is:

    =iif(count(Fields!Title.Value)=1,Fields!Title.Value,"")

    By doing this i have solved my issue.

    Thanks all for the kind support.

    Regards

    Rajni

    

    • Marked as answer by Rajni Kaushal Thursday, April 04, 2013 8:52 AM
    Thursday, April 04, 2013 8:51 AM
  • Hi Rajni,

    Here has a MSDN document baou how to add group, please see:
    Lesson 6: Adding Grouping and Totals (Reporting Services)

    Regards,


    Charlie Liao
    TechNet Community Support

    Thursday, April 04, 2013 9:16 AM
  • Thanks Charlie for the help:)

    Regards

    Rajni

    Thursday, April 04, 2013 9:33 AM