Hide Table based on the visibility of another table

Traitée Hide Table based on the visibility of another table

  • Tuesday, July 31, 2012 2:32 PM
     
     

    Hi

    I am having 2 table in my SSRS report. I want to show only one table. If one table is visible another table should not be visible and vise versa. So can anyone help me to solve this issue please.

    Thanks & Regards,
    Kishore


    Kishore

All Replies

  • Tuesday, July 31, 2012 4:19 PM
     
     

    You have an expression for the the Visibility property of one table, yes? Something like:

    =IIF(<compare here>, True, False)

    Then simply reverse the True/False in the visibiltiy property of the second table:

    =IIF(<compare here>, False, True)


    Todd C - MSCTS SQL Server 2005, MCITP BI Dev 2008 Please mark posts as answered where appropriate.

  • Tuesday, July 31, 2012 4:40 PM
     
     

    Hi Kishore,

    Can you please let me know if both your tables make use of the same dataset or if they use different ones?

    Cheers,
    IceQB


    Please mark correct answers :)

  • Wednesday, August 01, 2012 5:12 AM
     
     

    Hi Todd,

    Thanks for posting. I know the expression, but i dont know how to write the Contion statement. So could you please write the condition for me.

    Thanks & Regards,
    Kishore


    Kishore

  • Wednesday, August 01, 2012 5:13 AM
     
     

    Hi Sumanth,

    Thanks for the reply. Two different data sets have used for the two tables.

    Thanks & Regards,
    Kishore


    Kishore

  • Wednesday, August 01, 2012 6:47 AM
    Moderator
     
     

    Hello Kishore,

    Thank you to post your question on TechNet forum.

    I want to check what is the relationship between the two tables. If they rely on the certain logic, please create a variable on the page and set the variable value as the logic result. On the table visibility tab, we can set the hidden variable to the variable.

    I hope it is helpful to you. If you want to get more detail information, please try to provide the following information.

    • What is the relationship of the two tables? When does the report show either of them?
    • If the logic is relative to the fields in two datasets, please provide us the datasets structure.

    Regards,

    Edward


    Edward Zhu

    TechNet Community Support

  • Wednesday, August 01, 2012 8:24 AM
     
     Answered

    Hello Kishore,

    as per my understanding you have two dataset and for that you are using either different parameter or different values.

    make 1 textbox in your report name is specific i.e. VisibleData

    =IIF(Parameters!Parameter.Value="table1",true.false)  [you can use your appropriate condition.]

    write this expression in its expression value and make it hidden.

    now, in your table1 visibility property, write below code

    =iif(ReportItems![VisibleData].Value = "True",true,false)

    for table2,

    =iif(ReportItems![VisibleData].Value = "True",false,true)

    hope you get your answer


    Touseef

    • Marked As Answer by Kishorekv Wednesday, August 01, 2012 1:45 PM
    •