Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Joining text with formatted headers

Hi, i have four text fields that i wish to show on a dashaboard. I could add them singly to cards, but this will potentially waste a lot of space as the fields will be of varying character length resulting in some fields not fitting and others having lots of white space. 

I wonder if it is possible to concatenate these fields and have a formatted header between each, e.g. something like the below:-concat columns.png

2 ACCEPTED SOLUTIONS
dax
Community Support
Community Support

Hi NotDave, 

There is no visual for this format currently. One workaround is that you could try to use Card Browse (import this from powrbi market),   then modify your data to below(Eidt Query->choose four field->unpivot columns)

190.PNG

 Then use Card Browser like below

191.PNG192.PNG

Best Regards,
Zoe Zhi

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

Anonymous
Not applicable

Please see details in this post on how i have achieved the result. Note the linked post discusses what to do when a field is blank but discusses how to concatenate text and code to build HTML.

I also used the HTMLviewer visual

 

https://community.powerbi.com/t5/Desktop/If-blank-dax-statement/m-p/829816/thread-id/398653#M399056

View solution in original post

3 REPLIES 3
dax
Community Support
Community Support

Hi NotDave, 

There is no visual for this format currently. One workaround is that you could try to use Card Browse (import this from powrbi market),   then modify your data to below(Eidt Query->choose four field->unpivot columns)

190.PNG

 Then use Card Browser like below

191.PNG192.PNG

Best Regards,
Zoe Zhi

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Anonymous
Not applicable

Hi, unfortunatelyt this is not what i am looking for. I am hoping to merge fields of varying length into one string and format the headers of each field to identify the separate fields that have been merged. The reason for this is to reduce the amoung ot white space in the report and to allow one long field to be merged with two shorter fields.

The solution - as i understand it - will have a similar amount of white space as 4 separate cards each pointed to an individual field.

 

Is there a way to construct and display HTML? E.g, taking the field headers and wrap in <h1> tags, the field text and wrap in <p> tags and concatenating all this together.

 

<h1>Field One Header</h1>
<p>Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text Field one text</p>
<h1>Field Two Header</h1>
<p>Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field Field two text longer text for this field</p>
<h1>Field Three Header</h1>
<p>Field three text shorter text for this field</p>
Anonymous
Not applicable

Please see details in this post on how i have achieved the result. Note the linked post discusses what to do when a field is blank but discusses how to concatenate text and code to build HTML.

I also used the HTMLviewer visual

 

https://community.powerbi.com/t5/Desktop/If-blank-dax-statement/m-p/829816/thread-id/398653#M399056

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.