Product Documentation
Select a Product:
Find Text:
Submit a question:
Not seeing an answer to a question you might have? You can ask it here and we'll try to update the documentation to address it. If you're making a feature request or reporting a problem, please create a support item for it, instead!
Text From Values
Purpose
The Text from Values Visual lets you generate text output from source data in a wide range of formats - or you can roll your own output format using a simple yet powerful template language. Useful for building content to share in posts, emails, chat and more. Also useful for creating tabular export data that can be copied and pasted into other applications, with tailoring beyond what Power BI provides out of the box.
Data Bucket
The data requirements for the Text From Values visual includes 2 bucket fields:
| Field | Type | Description |
|---|---|---|
| Value Source | Any | One or more fields that are reflected into the visual as a table of rows and columns. The actual output is based on a transformation of this tabular data, using an output format. |
| Template Source (optional) (in 1.2) | Any | Optionally provide the text for your template through your semantic model as a source. |
Settings
Data and Interaction
| Field | Default | Description | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Preset Output Format | CSV Tabular | Controls how the text output will be formatted. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| User Template |
If the output format is set to 'User Template', this value is used to generate the text.
A template is composed of plain text that can contain markup to indicate where values should be inserted. Markup tags are prefixed with "@" and can include:
Most markup tags other than @cell include a "body" portion which is contained within braces ({ and }) immediately following the markup tag. For example, in "@rows(){a}", "a" is the body portion of the markup tag.
Some tags require multiple body segments, such as @empty and @ifequals.
Complete examples of usage can be found below, in the section "User Templates". | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| No Data Template | Optionally provide template text that will be used if there is no data available. (in 1.2) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Change Detection Type | No Change Detection | Controls if/how change detection is applied. If change detection is enabled, @changed can be used in templates to control things like formatting, when changes are detected between refreshes. (in 2.2) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Change Detection Template | You can optionally define a template where the output reflects a 'state' that can be checked for changes across refreshes of the visual. This lets you do things such as highlight values when they change, on a refresh (scheduled or manual). The template format matches the same template language used for rendering. You will typically use the @changed function in a user-defined template to see if the value that's evaluated from this template changes. (Some preset formats may override this template value, and you can pick a preset changed type, or create your own using 'Change Template (setting)' for the 'Change Detection Type' setting.) (in 2.2) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Change Auto Signals | Off | When enabled (and when change detection is enabled), any detected change will 'signal', which can have visual effects that can persist across refreshes. This is equivalent to using @changed and @signal together in a template. (in 2.2) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Signal Dismissal Type | Link | Controls if/how a signaled state can be cleared. (in 2.2) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Signal Dismissal Interval | 60 | When the 'Signal Dismissal Type' setting is set to 'Timer', this contains the number of seconds to wait before the signal state is automatically dismissed. (in 2.2) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Column Override Expressions |
Allows one to override global settings which apply to columns. General format is to have one expression, per line, for columns that requires any overrides. Column expressions are composed of one or more key-value pairs, which are delimited with semi-colons (;). Keys are separated from values with an equals sign (=). Valid keys include:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Default Aggregation Mode | Sum/Max/Concatenate | If the visual has grouped columns, identifies the default aggregation to use for any non-grouped columns. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Default Merge Mode | Best Fit | If the visual has merged values, defines the default behavior when creating output for that merged value. (eg. if 'ABC' and 'Abc' merge due to case insensitivity, determines which value is output.) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Include Header Row | Off | When enabled, a header row (row 0) is included based on the display values for the corresponding data fields. Some preset formats override this setting. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Quote Blank Values | On | When enabled, blank values will be enclosed in the field delimiter that applies (eg. double-quotes). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Format Numerics | Off | When enabled, numeric values by default are formatted using locale-specific rules, otherwise they are left unformatted (raw). (in 1.1) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Copy Format | Auto | When the copy link is used, identifies the format to use for the clipboard format. (in 2.0) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Maximum Rows | 10000 | Regardless of what may be specified in any user template for rows to 'take', this is a global limit on the number of rows allowed to process. This helps ensure performance does not accidentally degrade, although you can change this to higher (or lower) values as required. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Default Sort Order | Ascending | Defines the default sort order applied to all grouped columns, in order of appearance. Individual ordering is possible through use of column override expressions. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Case Must Match | On | When disabled, case is not required to match (allowing for the possibility of merging rows). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Ignore Non-alphanumeric | Off | When enabled, internally compares only alphanumeric characters, for merge purposes. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Keep Whitespace | Off | When enabled, whitespace must match whitespace between compared values, for merge purposes (regardless of 'Ignore Non-alphanumeric' setting). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Diacritic Neutral | Off | When enabled, internally compares diacritic (accented) characters as if ASCII characters, for merge purposes. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Fuzzy Matching | Off | When enabled, similar text values are allowed to merge, based on fuzzy matching rules. This is most useful when dealing with whole words, versus codes and identifiers. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Default Group By | Off | Provides the default 'group by' property for every column present. Enabled implies all columns can be grouped by default (effectively picks distinct rows). Disabled implies no columns are grouped (no aggregation will be applied). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Concatenation Separator | When concatenation is applied, is the text used to separate terms. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Select All | On | When enabled, setting focus to the text box causes all text to be selected. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Use Default Context Menus | Off | When enabled, context menus on text controls will be the browser default as opposed to the Power BI context menu. This gives you the option to use browser menu features (eg. copy). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Allow Tooltips | On | When enabled, tool-tips may be shown when hovering over the text area. (in 1.1) |
Formatting
| Field | Default | Description | ||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| General Style | Base Default | Offers some different general styles for the visual. (in 1.1) | ||||||||||||||||||||||||||
| Extended Mark-up | Off |
When enabled, the template can include special markup elements, similar to HTML. This changes the nature of the visual to be in-line scrollable text, instead of a textarea control. Note: you must correctly pair start and end tags. Listed below are allowed markup tags. (in 1.2)
| ||||||||||||||||||||||||||
| Text Read Only | On | When enabled, the text area will be read-only. (in 1.1) | ||||||||||||||||||||||||||
| Word Wrap | On | When enabled, word-break word wrapping will be used for the generated text area. (in 1.1) | ||||||||||||||||||||||||||
| Show Copy Clipboard | Off | When disabled, the copy to clipboard link will be hidden. Note: copy functionality varies based on browser used. (in 2.0) | ||||||||||||||||||||||||||
| Copy Outer (Extended) | Off | When enabled, the container HTML is copied, when using extended markup mode. This includes some container formatting (e.g. color). (in 2.0) | ||||||||||||||||||||||||||
| Show Ctrl-C Message | Off | When enabled and when one or more characters are selected in the text area, a message can be shown indicating to the user that they can pretty Ctrl-C to copy the selected text to the clipboard. | ||||||||||||||||||||||||||
| Copied Message Duration | 4 | The number of seconds to display the 'copied data to clipboard' message. Use zero to show no message. (in 2.0) | ||||||||||||||||||||||||||
| Show Loading Message | On | When enabled, the loading message will be shown below the value entry control. | ||||||||||||||||||||||||||
| Show Counts | On | When enabled, rows loaded and matched counts are shown. | ||||||||||||||||||||||||||
| Extended Markup: Horizontal Alignment | Center | When extended markup is used, controls horizontal text alignment, for all lines of output. (in 1.2) | ||||||||||||||||||||||||||
| Extended Markup: Vertical Alignment | Middle | When extended markup is used, controls vertical text alignment, for all output text. (in 1.2) | ||||||||||||||||||||||||||
| Extended Markup: Image Size | 24 | When using the img tag, identifies the width and height for the image, in pixels. (in 1.2) | ||||||||||||||||||||||||||
| Use Model Formatting | Off | When enabled, format strings will be taken from the semantic model. When disabled, you can use settings such as 'Date Format String' to control formatting, independently of the model. (in 2.2) | ||||||||||||||||||||||||||
| Date Format String | L | For values which are dates, specifies the date format to use. (Default of 'L' uses locale-specific date-only formatting.) Valid date formats are explained more here. | ||||||||||||||||||||||||||
| Currency Code | USD | If the formatting for the value is set as 'currency', this indicates the general currency type, in ISO 4217 currency code format (eg. USD). | ||||||||||||||||||||||||||
| Numeric Max Decimal | 2 | For values that are numbers (and Format Numerics is enabled), specifies the maximum number of decimal places. | ||||||||||||||||||||||||||
| Numeric Min Decimal | 0 | For values that are numbers (and Format Numerics is enabled), specifies the minimum number of decimal places. | ||||||||||||||||||||||||||
| Generated Text Size | 10.5 | The size of the generated text. | ||||||||||||||||||||||||||
| Generated Text Font | The font family for the generated text. | |||||||||||||||||||||||||||
| Counter Text Size | The size of the counter text. (in 2.1) | |||||||||||||||||||||||||||
| Counter Text Font | The font family for the counter text. (in 2.1) | |||||||||||||||||||||||||||
| Additional Inner Padding | 0 | Allows additional padding to be included between elements within the visual. | ||||||||||||||||||||||||||
| Clear Signal/Alert Text | Clear Alert | When the visual enters into a signaled state and the 'Signal Dismissal Type' setting is set to 'Link', this is the text used for the link. (in 2.2) | ||||||||||||||||||||||||||
| Copy Link Text | Copy | Text to show for the 'Copy' link. (in 2.2) | ||||||||||||||||||||||||||
| Copied Message Text | Copied to clipboard. | Text to show for the 'Copied to clipboard' message. (in 2.2) | ||||||||||||||||||||||||||
| Loading Text | Loading | Text to show for the 'Loading' message. | ||||||||||||||||||||||||||
| Loaded Text | loaded | Text to show for the 'loaded' count text. | ||||||||||||||||||||||||||
| Message: Template Error | Template error: {0} | Text to show when there is a template parsing issue. (Allows {0}) |
Colors
| Field | Default | Description |
|---|---|---|
| Text Color | The color override for general text within the visual. | |
| Text Area Background Color | The background color override for the generated text area. | |
| Background Color | The background color for the visual's whitespace areas. | |
| Signaled Background Color | When the visual is in a signaled state, this can serve as a background color override, in absence of another background color setting (eg. set via @bgcolor). (in 2.2) | |
| Background Opacity | 100 | The opacity (percentage) for the background color. (Zero is fully transparent.) |
Animation Defaults
| Field | Default | Description |
|---|---|---|
| Animation Type | None or in Template | Controls if an animation will be shown inside the visual, on rendering. (in 2.3) |
| Split Delimiter | --- | The text included here can be used with 'split' animation types to create one or more 'subcards' that are cycled through. (in 2.5) |
| Run After (seconds) | 0 | The number of seconds to wait until the animation is performed. (Applies to all types except Curtain.) (in 2.4) |
| Confetti: Particles | An override for the number of confetti particles to show, covering both falling and exploding confetti. The default (and 0) is based on the size of the visual. (in 2.3) | |
| Confetti: Delay | When set, the number of milliseconds to wait between animation frames for falling confetti. Larger numbers imply a slower confetti drop. For exploding confetti, introduces a delay between individual explosions. (in 2.3) | |
| Confetti: Hide After | When set, the confetti drop will stop after this number of milliseconds; confetti explosions will keep happening until this time elapses. When not set (or zero), the confetti fall animation never stops, or the confetti explosion only happens one time. (in 2.3) | |
| Curtain: Open After | When set, the curtain will open after this number of milliseconds. When not set (or zero), the curtain will not open automatically but can still be clicked to open. (in 2.3) | |
| Curtain: Left Panel Text | You can optionally specify text to show on the left curtain panel. (in 2.3) | |
| Curtain: Right Panel Text | You can optionally specify text to show on the right curtain panel. (in 2.3) | |
| Curtain: Text Alignment | Right/Left | Controls how any text is aligned on the curtain surface. Note that Right/Left allows text on the left curtain to sit directly adjacent to text on the right curtain, allowing for words to appear continuous over both sides. (in 2.3) |
| Curtain: Text Font | The font family for any text used on the curtain surface. (in 2.3) | |
| Curtain: Text Size | 10.5 | The size of any text used on the curtain surface. (in 2.3) |
| Curtain: Color | The color for the closed curtains. (Default = orange) (in 2.3) | |
| Curtain: Text Color | The color to use for text on the curtain surface. (Default = white) (in 2.3) | |
| Explosion: Style | Centralized (default) | Controls the style for the confetti explosion animation. (in 2.4) |
| Explosion: Horizontal Center | 50 | For exploding confetti, identifies the horizontal position as the origin of the explosion. Scale is a percentage: 0 (left-most) to 100 (right-most). (in 2.4) |
| Explosion: Vertical Center | 75 | For exploding confetti, identifies the vertical position as the origin of the explosion. Scale is a percentage: 0 (top-most) to 100 (bottom-most). (in 2.4) |
| Marquee: Direction | Up | Controls the direction of scroll for the marquee animation. (in 2.4) |
| Marquee: Off Screen | On | When enabled, the marquee begins scrolling from off-screen. (in 2.4) |
| Marquee: Speed | Controls how fast the marquee scrolls. In pixels per second. When 0, determines based on the visual size. (in 2.4) | |
| Transition: Delay | 5000 | The number of milliseconds to wait before a transition (e.g. flip, fade) is invoked. Minimum granularity is 100 milliseconds, default is 6 seconds. (in 2.5) |
| Split: Background Colors | A semi-colon delimited list of colors which are used as background colors for cards which are being animated with a split style. Colors are cycled sequentially. Color can be a named color (e.g. 'red') or a hex color (e.g. #ff0000). Default = orange (in 2.5) | |
| Split: Foreground Colors | A semi-colon delimited list of colors which are used as foreground colors for cards which are being animated with a split style. Colors are cycled sequentially. Color can be a named color (e.g. 'red') or a hex color (e.g. #ff0000). Default = black (in 2.5) | |
| Flip/Fade: Speed (ms) | 1000 | The speed of the flip/fade for those animation styles, in milliseconds. (default = 1000ms) (in 2.5) |
| Flip/Fade Style | Rounded | When using the flip/fade animation styles, controls the display style for the nested card. (in 2.5) |
| Split: Click Advances | On | When enabled, clicking on the card will advance to the next subcard. (in 2.5) |
| Fade: Approach | Out Then In | When using the fade animation style, controls how the fade is applied. (in 2.5) |
Site License and Diagnostics
| Field | Default | Description |
|---|---|---|
| Licensed By | Provide the name that the product was registered with, as found in the confirmation email. | |
| Site License Key | For site licensing (not from AppSource). Provide the 22 character license key, as found in the confirmation email. (Note: a reload of the report is needed after the key and licensee is set.) | |
| Hide Desktop Watermark | Off | When enabled, the footer watermark for Power BI Desktop is hidden. (The watermark provides useful information about support, etc.) |
User Templates
Preset output formats are based on the sample template language that you can use to create your own templates. Here are a few complete examples:
CSV Tabular
@rows(){@columns(){@cell()}}
- Iterates all columns within all rows, using all defaults for delimiters. The visual setting "Include Header" controls whether a header row is included or not.
CSV Tabular, Pivoted
@pivot(){@rows(){@columns(){@cell()}}}
- Similar to CSV Tabular, but wraps the entire template with a pivot of columns to rows and rows to columns.
TSV Tabular
@rows(){@columns("\t"){@cell("[\t\n\r\"]")}}
- Uses Tab as the column delimiter and still quote-delimits but over a smaller range of cell values (Tab, line feeds and double quotes).
TSV Tabular, Pivoted
@pivot(){@rows(){@columns("\t"){@cell("[\t\n\r\"]")}}}
- Similar to TSV Tabular, but wraps the entire template with a pivot of columns to rows and rows to columns.
Pivot Columns, No Blanks, Blanks Between Rows
@rows("\r\n\r\n"){@columns("\r\n",false){@cell("","")}}
- Present every column on a new line, with an extra line break between rows.
- Do not include blank values.
Pivot Columns With Labels, Blanks Between Rows
@rows("\r\n\r\n",,1){@columns("\r\n"){@cell("","",,0): @cell("","")}}
- Present every column on a new line, with an extra line break between rows.
- Rows will the show column heading value, followed by a colon, followed by the cell value.
- Header row will be included, regardless of global setting.
- The header row is skipped for iteration, but it is referenced in the first @cell use
First Row, Pivot Columns, No Blanks
@rows(,1){@columns("\r\n",false){@cell("","")}}
- Similar to "Pivot Columns, No Blanks, Blanks Between Rows", but only the first row will be emitted.
- Do not include blank values.
- Useful if one is filtering to a specific entity that one wishes to build a data card for.
First Row, Pivot Columns With Labels
@rows(,1,1){@columns("\r\n"){@cell("","",,0): @cell("","")}}
- Similar to "Pivot Columns With Labels, Blanks Between Rows", but only the first row will be emitted.
- Rows will the show column heading value, followed by a colon, followed by the cell value.
- Header row will be included, regardless of global setting.
- The header row is skipped for iteration, but it is referenced in the first @cell use
- Useful if one is filtering to a specific entity that one wishes to build a data card for.
HTML Table (Style 1)
<table cellSpacing="1" cellPadding="1" width="100%" border="1">@rows(){<tr>@columns(""){<td>@escape(html){@cell("","")}</td>}</tr>}</table>
- Generates lightly a formatted HTML table for all rows and columns.
HTML Table (Style 1), With Header
<table cellSpacing="1" cellPadding="1" width="100%" border="1"><thead>@rows(,1){<tr>@columns(""){<th align="center" bgColor="tan"><strong>@escape(html){@cell("","")}</strong></th>}</tr>}</thead><tbody>@rows(,,1){<tr>@columns(""){<td>@escape(html){@cell("","")}</td>}</tr>}</tbody></table>
- Generates lightly a formatted HTML table for all rows and columns.
- Header row will be included, regardless of global setting.
- A table header will be included with column names.
Single Field per Row: Flip Transition
@animation(5)@rows(){---<b>@cell(\"\",,0)</b>}
- Takes all rows and shows the first column on pages that "flip" (using the animation setting). Animation speed can be adjusted in settings.
- Key concept: the --- acts as a delimiter between "frames" of the animation. Empty frames are skipped. You can change the delimiter text in settings.
Other Resources / Links:
Learn more about purchasing one or more user licenses from Microsoft AppSource.