Forum Discussion

abhi87's avatar
abhi87
Icon for Helper I rankHelper I
5 years ago
Solved

How to keep card visualization blank when report is opened

Hello,

 

I was wondering how to keep the card visualization blank when the Power BI dashboard is opened, I'm working with sesentive data so I don't want the information to show unless it's asked for.

 

So, I have a table with crashkey number and other attributes, and I have another table with the same crashkey numbers and narrative for each crashkey. If someone clicks on a crashkey, I want the corresponding narrative to come up in the card visualization, I have already linked the tables and everything is set up. When I click on a crashkey the specific narrative comes up, but by default the visualization is pre-pollutated with couple narratives when the dashboard is open, which I don't want. I was wondering if there is any way for me to keep the visualization blank until I pick a crashkey or if there is any other visualization I can use to achieve this.

 

Sorry if the question is confusing to understand, it's my first time posting on the forum.

10 Replies

  • abhi87 if it is a measure you have to use aggregation, change it to something like this

     

    Measure = IF (HASONEVALUE(CRASH_LEVEL[CRASH_KEY]), MAX(CombinedNarratives[CombinedNarrative]))

     

    ✨ Follow us on LinkedIn

     

    Check my latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

     

    ⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡

    • abhi87's avatar
      abhi87
      Icon for Helper I rankHelper I

      parry2k It seems like the measure didn't do anything, the card visual is still pre-pollutated when no crashkey is selected/when the dashboard is opened

  • abhi87 with custom message:

     

    Measure = IF (HASONEVALUE(CRASH_LEVEL[CRASH_KEY]), MAX(CombinedNarratives[CombinedNarrative]),
    "Select a data point" )

     

    ✨ Follow us on LinkedIn

     

    Check my latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

     

    ⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡

  • abhi87 you can check if a crashkey is selected then only show the value, add a measure something like this that you can use in card visual

     

    Measure =
    IF ( HASONEVALUE ( YourTable[CrashKey] ), [Whatever you want to show on CARD VISUAL] )

     

    ✨ Follow us on LinkedIn

     

    Check my latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

     

    ⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡

    • abhi87's avatar
      abhi87
      Icon for Helper I rankHelper I

      parry2k When I type up the measure function I'm getting a error saying, "A single value for column 'CombinedNarrative' in table 'CombinedNarratives' cannot be determined. This can happen when a measure formula refers to a column that contains many values without specifying an aggregation such as min, max, count, or sum to get a single result." The narrative I have in my data is a text value.

       

      This is the measure function I used

      Measure = IF (HASONEVALUE(CRASH_LEVEL[CRASH_KEY]), (CombinedNarratives[CombinedNarrative]))
       
      So, the two tables I have are CRASH_LEVEL and CombinedNarratives, I have linked the CRASH_KEY between the two tables.
  • abhi87 did you used that measure in the card visual? Share the sample pbix file using one drive/google drive, remove sensitive information before sharing. Not sure why it is not working.

    • abhi87's avatar
      abhi87
      Icon for Helper I rankHelper I

      parry2k thank you it works now. I realized that I didn't use the measure in the card visual

  • abhi87 i think it is working as expected, not sure what you are expecting, when I opened the file it is blank and when I'm selecting a data point it is giving the message, what you are looking for? if this is not what you want, then explain it further.

     

  • abhi87 because you are not using the measure in the card visual and I asked this previously, and you said "yes" which is not the case when I saw your file, and that's why you are seeing the value.

     

    We are going in circles for no reason.

     

    ✨ Follow us on LinkedIn

     

    Check my latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

     

    ⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡

    • abhi87's avatar
      abhi87
      Icon for Helper I rankHelper I

      parry2k yes, I realized that. I interpreted the question differently but understood it now. Thank you so much for the help. I have one other follow up question, is there a way to replace that "(blank)" with a custom message?