cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
danextian
Resident Rockstar
Resident Rockstar

Cannot select a measure as a visual title

Hello,

 

I don't know what I am missing. I can't select a measure as a dynamic title of a visual. The measures are in the dropdown but can' be selected.  dynamic visual title.png

Did I answer your question? Mark my post as a solution!
"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
www.linkedin.com/in/danebelarminocpa
1 ACCEPTED SOLUTION

@danextian 

 

You may try adding CONVERT.

https://community.powerbi.com/t5/Desktop/expression-that-yield-variant-data-type-cannot-be-used-to-d...

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

7 REPLIES 7
molegris
Helper II
Helper II

Hi,

Just for those who are still struggling despite the advise to use CONVERT.  You might have done the same mistake I did.  CONVERT is not going to work alone... you need to change the type on the settings of the measure.  duh!  can't beleive I missed it!

Actually, after changing the type in the settings part, I didn't even need to use the CONVERT function.

Capture d’écran 2021-02-10 152411.png

 

regards,

--mo

jochenj
Advocate II
Advocate II

i have the same issue: measure is visible but not selectable in the dialog of Title Expression 

Tried with simplest possible measure without success:
lblX = "My Custom Title"

 

The only thing i can choose in this "Title Text" dialog are COLUMNS but not MEASURES 

Any hints? 

Thanks,

 

Gordonlilj
Solution Sage
Solution Sage

Hi,

 

What is the datatype for the measure?

I belive measures used for titles must must be a string datatype for it to work

The measure is a string that shows a range of dates with this format: dd/mm/yy - dd/mm/yy.

Did I answer your question? Mark my post as a solution!
"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
www.linkedin.com/in/danebelarminocpa

Could you post the entire measure?

I'm posting a different measure since the period range measure is dependent on othe pretty long measures. This one is pretty simple but still I can't select this as a visual title.

P&L Overview text =
VAR __RANGE =
    SELECTEDVALUE ( 'Actual vs Benchmark Measures'[Range] )
VAR __BENCHMARK =
    SELECTEDVALUE ( 'Actual vs Benchmark Measures'[Benchmark] )
RETURN
    "P&L Overview " & __RANGE & " " & __BENCHMARK
Did I answer your question? Mark my post as a solution!
"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
www.linkedin.com/in/danebelarminocpa

@danextian 

 

You may try adding CONVERT.

https://community.powerbi.com/t5/Desktop/expression-that-yield-variant-data-type-cannot-be-used-to-d...

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
Power BI October Update 2021.jpg

Power BI Release

Click here to read more about the October 2021 Release!

Microsoft Ignite 768x460.png

Find your focus

Explore the latest tools,training sessions,technical expertise, networking and more.

Power BI Womens Summit 2021 768 x460.jpg

Interviews, learning sessions, allies, and more!

#PowerBIWomenSummit

Teds Dev Camp Oct. 2021 768x460.jpg

Power BI Dev Camp - October 28th, 2021

Mark your calendars and join us for our next Power BI Dev Camp!