{"id":3024,"date":"2020-05-07T11:47:17","date_gmt":"2020-05-07T09:47:17","guid":{"rendered":"https:\/\/thebipower.fr\/?p=3024"},"modified":"2023-01-29T14:03:21","modified_gmt":"2023-01-29T13:03:21","slug":"visuals-labels-translations-in-power-bi-reports","status":"publish","type":"post","link":"https:\/\/thebipower.fr\/index.php\/2020\/05\/07\/visuals-labels-translations-in-power-bi-reports\/","title":{"rendered":"Visuals labels translations in Power BI reports"},"content":{"rendered":"\n<p>Visuals labels translations in Power BI reports are not supported natively. However, there is a trick using conditional formating which does the job. The most used visual labels are titles so I will focus on this kind of label in this post.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Steps to translate visuals titles<\/h2>\n\n\n\n<div class=\"wp-block-media-text alignwide\" style=\"grid-template-columns:63% auto\"><figure class=\"wp-block-media-text__media\"><img loading=\"lazy\" decoding=\"async\" width=\"609\" height=\"175\" src=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Create-a-table-with-the-translations.png\" alt=\"Visuals translations Power BI reports\" class=\"wp-image-3048 size-full\" srcset=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Create-a-table-with-the-translations.png 609w, https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Create-a-table-with-the-translations-300x86.png 300w\" sizes=\"(max-width: 609px) 100vw, 609px\" \/><\/figure><div class=\"wp-block-media-text__content\">\n<p class=\"has-normal-font-size\">Create a table with the translations including an ID column (here the ID column is the &#8220;Reference text&#8221;)<\/p>\n<\/div><\/div>\n\n\n\n<div class=\"wp-block-media-text alignwide\" style=\"grid-template-columns:63% auto\"><figure class=\"wp-block-media-text__media\"><img loading=\"lazy\" decoding=\"async\" width=\"590\" height=\"164\" src=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Amount-by-category-measure.png\" alt=\"Visuals translations Power BI reports\" class=\"wp-image-3050 size-full\" srcset=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Amount-by-category-measure.png 590w, https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Amount-by-category-measure-300x83.png 300w\" sizes=\"(max-width: 590px) 100vw, 590px\" \/><\/figure><div class=\"wp-block-media-text__content\">\n<p class=\"has-normal-font-size\">Create a DAX measure by visual. This measure will look for the translation according to an ID value<\/p>\n<\/div><\/div>\n\n\n\n<div class=\"wp-block-media-text alignwide\" style=\"grid-template-columns:21% auto\"><figure class=\"wp-block-media-text__media\"><img loading=\"lazy\" decoding=\"async\" width=\"181\" height=\"172\" src=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Text-conditional-formating.png\" alt=\"Visuals translations Power BI reports\" class=\"wp-image-3051 size-full\"\/><\/figure><div class=\"wp-block-media-text__content\">\n<p class=\"has-normal-font-size\">For each visual, open the formating pane then activate and develop the &#8220;Title&#8221; option. Click on the &#8220;fx&#8221; button besides the &#8220;Title text&#8221; field to add conditional formating. Then select the DAX measure<\/p>\n<\/div><\/div>\n\n\n\n<div style=\"height:20px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">DAX measure for text conditional formating <\/h2>\n\n\n\n<p>I found 3 methods to get the translated text. Both of them have pros and cons.  Please, give your opinion and share other methods.  <\/p>\n\n\n\n<ul>\n<li>Use a slicer to filter the language\n<ul>\n<li>This way, you can test different languages easily but the end user needs also to select his language<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>Use the &#8220;USERCULTURE()&#8221; function to filter the language\n<ul>\n<li>No selection is needed because it uses the &#8220;Application language&#8221; in the global regional settings<\/li>\n\n\n\n<li>This function works with some limitations (see down below) and it is not supported by Microsoft for the moment even if it works in some cases <\/li>\n\n\n\n<li>This is my favorite method. I&#8217;m just waiting for Microsoft to support it totally<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>Use row level security to filter the language\n<ul>\n<li>I didn&#8217;t explore this possibility yet because I don&#8217;t want to maintain a table to make a correspondance between users and languages<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Tabular editor script to create translation measures automatically<\/h2>\n\n\n\n<p>You understood that you need to create as many measures as visual titles you want to translate. It might be tedious. As Tabular Editor allows to create measures with a script, we will save a lot of time using a script like the one I propose. The script reads a tsv file (tab separated values) which contains measures names. A tsv file example is joined to the script :<\/p>\n\n\n\n<section class=\"wp-block-uagb-columns uagb-columns__wrap uagb-columns__background-none uagb-columns__stack-mobile uagb-columns__valign-center uagb-columns__gap-10 align uagb-block-6811a364 uagb-columns__columns-2 uagb-columns__max_width-theme\"><div class=\"uagb-columns__overlay\"><\/div><div class=\"uagb-columns__inner-wrap uagb-columns__columns-2\">\n<div class=\"wp-block-uagb-column uagb-column__wrap uagb-column__background-undefined uagb-block-44e8d7d0\"><div class=\"uagb-column__overlay\"><\/div>\n<p class=\"has-text-align-right\">Create visuals translations measures<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-uagb-column uagb-column__wrap uagb-column__background-undefined uagb-block-9b21ad49\"><div class=\"uagb-column__overlay\"><\/div>\n<div class=\"wp-block-buttons is-layout-flex wp-block-buttons-is-layout-flex\">\n<div class=\"wp-block-button\"><a class=\"wp-block-button__link wp-element-button\" href=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Create-visuals-translations-measures.zip\">Download<\/a><\/div>\n<\/div>\n<\/div>\n<\/div><\/section>\n\n\n\n<h2 class=\"wp-block-heading\">Read measures list from report layout<\/h2>\n\n\n\n<p>The list of measures can be created automatically reading the report layout in the pbix\/pbit file. In this post I describe how to create\/update the list with no effort. I describe also how to translate visual titles automatically :    <a href=\"https:\/\/thebipower.fr\/index.php\/2020\/05\/10\/automatic-translation-of-visuals-labels\/\">https:\/\/thebipower.fr\/index.php\/2020\/05\/10\/automatic-translation-of-visuals-labels\/<\/a> <\/p>\n\n\n\n<p>In a future post, I will explain how to maintain translations along the life of the report.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Limitations<\/h2>\n\n\n\n<p>The following documentation from Microsoft describes how to and advices on several limitations.<br>Expression based titles in Power BI desktop  :   <a rel=\"noreferrer noopener\" aria-label=\" (opens in a new tab)\" href=\"https:\/\/docs.microsoft.com\/fr-fr\/power-bi\/desktop-conditional-format-visual-titles\" target=\"_blank\">https:\/\/docs.microsoft.com\/fr-fr\/power-bi\/desktop-conditional-format-visual-titles<\/a><\/p>\n\n\n\n<p>This Power BI community post describes the temporary limitations of the &#8220;USERCULTURE()&#8221; DAX function :   <a rel=\"noreferrer noopener\" aria-label=\" (opens in a new tab)\" href=\"https:\/\/community.powerbi.com\/t5\/Service\/USERCULTURE-works-only-for-reports-implemented-with-import-mode\/m-p\/859004\" target=\"_blank\">https:\/\/community.powerbi.com\/t5\/Service\/USERCULTURE-works-only-for-reports-implemented-with-import-mode\/m-p\/859004<\/a><\/p>\n\n\n\n<p>As long as the XMLA endpoint read\/write access is in preview mode, I don&#8217;t recommend to use it in production. However, the solution above works so feel free to try on test reports<\/p>\n\n\n\n<p>Some labels are not able to use conditional formating : textbox text, visual header tooltip, page name<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion<\/h2>\n\n\n\n<p>So visuals labels translations are possible in Power BI reports. This does not concern the model translation. To translate name of columns, measures, display folders, &#8230; please have a look at this post :   <a href=\"https:\/\/thebipower.fr\/index.php\/2020\/04\/12\/automatic-translation-of-tabular-model\/\">https:\/\/thebipower.fr\/index.php\/2020\/04\/12\/automatic-translation-of-tabular-model\/<\/a><\/p>\n\n\n\n<div style=\"height:20px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n\t\t\t<div class=\"wp-block-uagb-post-carousel uagb-post-grid  uagb-post__image-position-top uagb-post__image-enabled uagb-block-2b60c133     uagb-post__arrow-outside uagb-post__items uagb-post__columns-3 is-carousel uagb-post__columns-tablet-2 uagb-post__columns-mobile-1\" data-total=\"1\" style=\"\">\n\n\t\t\t\t\t\t\t\t\t\t\t\t<article class=\"uagb-post__inner-wrap\">\t\t\t\t\t\t\t\t<div class='uagb-post__image'>\n\t\t\t\t\t\t\t\t\t<a href=\"https:\/\/thebipower.fr\/index.php\/2020\/07\/05\/translations-life-cycle-management\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\"><img loading=\"lazy\" decoding=\"async\" width=\"640\" height=\"341\" src=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/07\/Translations-life-cycle-management.jpg\" class=\"attachment-large size-large\" alt=\"Translations life cycle management\" srcset=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/07\/Translations-life-cycle-management.jpg 640w, https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/07\/Translations-life-cycle-management-300x160.jpg 300w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\t\t\t\t\t<\/a>\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t<h4 class=\"uagb-post__title uagb-post__text\">\n\t\t\t\t<a href=\"https:\/\/thebipower.fr\/index.php\/2020\/07\/05\/translations-life-cycle-management\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\">Translations life cycle management<\/a>\n\t\t\t<\/h4>\n\t\t\t\t\t\t<div class='uagb-post__text uagb-post-grid-byline'>\n\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t<div class='uagb-post__text uagb-post__excerpt'>\n\t\t\t\t\t<p>Translations life cycle management must be considered seriously as soon as we decide to translate&#8230;\t\t\t\t<\/div>\n\t\t\t\t\t\t<div class=\"uagb-post__text uagb-post__cta wp-block-button\">\n\t\t\t\t<a class=\"wp-block-button__link uagb-text-link\" href=\"https:\/\/thebipower.fr\/index.php\/2020\/07\/05\/translations-life-cycle-management\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\">Read More<\/a>\n\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t\t\t\t<\/article>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<article class=\"uagb-post__inner-wrap\">\t\t\t\t\t\t\t\t<div class='uagb-post__image'>\n\t\t\t\t\t\t\t\t\t<a href=\"https:\/\/thebipower.fr\/index.php\/2020\/05\/10\/automatic-translation-of-visuals-labels\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\"><img loading=\"lazy\" decoding=\"async\" width=\"468\" height=\"158\" src=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations.png\" class=\"attachment-large size-large\" alt=\"Visuals translations Power BI reports\" srcset=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations.png 468w, https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations-300x101.png 300w\" sizes=\"(max-width: 468px) 100vw, 468px\" \/>\t\t\t\t\t<\/a>\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t<h4 class=\"uagb-post__title uagb-post__text\">\n\t\t\t\t<a href=\"https:\/\/thebipower.fr\/index.php\/2020\/05\/10\/automatic-translation-of-visuals-labels\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\">Automatic translation of visuals labels<\/a>\n\t\t\t<\/h4>\n\t\t\t\t\t\t<div class='uagb-post__text uagb-post-grid-byline'>\n\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t<div class='uagb-post__text uagb-post__excerpt'>\n\t\t\t\t\t<p>Automatic translation of visuals labels in Power BI reports is possible using conditional formating, Tabular&#8230;\t\t\t\t<\/div>\n\t\t\t\t\t\t<div class=\"uagb-post__text uagb-post__cta wp-block-button\">\n\t\t\t\t<a class=\"wp-block-button__link uagb-text-link\" href=\"https:\/\/thebipower.fr\/index.php\/2020\/05\/10\/automatic-translation-of-visuals-labels\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\">Read More<\/a>\n\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t\t\t\t<\/article>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<article class=\"uagb-post__inner-wrap\">\t\t\t\t\t\t\t\t<div class='uagb-post__image'>\n\t\t\t\t\t\t\t\t\t<a href=\"https:\/\/thebipower.fr\/index.php\/2020\/04\/12\/automatic-translation-of-tabular-model\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\"><img loading=\"lazy\" decoding=\"async\" width=\"614\" height=\"159\" src=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/04\/Automatic-translation-of-tabular-model.png\" class=\"attachment-large size-large\" alt=\"Automatic translation of tabular model\" srcset=\"https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/04\/Automatic-translation-of-tabular-model.png 614w, https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/04\/Automatic-translation-of-tabular-model-300x78.png 300w\" sizes=\"(max-width: 614px) 100vw, 614px\" \/>\t\t\t\t\t<\/a>\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t<h4 class=\"uagb-post__title uagb-post__text\">\n\t\t\t\t<a href=\"https:\/\/thebipower.fr\/index.php\/2020\/04\/12\/automatic-translation-of-tabular-model\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\">Automatic translation of tabular model<\/a>\n\t\t\t<\/h4>\n\t\t\t\t\t\t<div class='uagb-post__text uagb-post-grid-byline'>\n\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t<div class='uagb-post__text uagb-post__excerpt'>\n\t\t\t\t\t<p>Automatic translation of tabular model using Tabular Editor and Excel is possible since the Power&#8230;\t\t\t\t<\/div>\n\t\t\t\t\t\t<div class=\"uagb-post__text uagb-post__cta wp-block-button\">\n\t\t\t\t<a class=\"wp-block-button__link uagb-text-link\" href=\"https:\/\/thebipower.fr\/index.php\/2020\/04\/12\/automatic-translation-of-tabular-model\/\" target=\"_self\" rel=\"bookmark noopener noreferrer\">Read More<\/a>\n\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t\t\t\t<\/article>\n\t\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t","protected":false},"excerpt":{"rendered":"<p>Visuals labels translations in Power BI reports are not supported natively. However, there is a trick using conditional formating which does the job. The most used visual labels are titles so I will focus on this kind of label in this post. Steps to translate visuals titles Create a table with the translations including an&#8230;<\/p>\n","protected":false},"author":2,"featured_media":3037,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_uag_custom_page_level_css":"","_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_uf_show_specific_survey":0,"_uf_disable_surveys":false,"_kad_post_transparent":"","_kad_post_title":"","_kad_post_layout":"","_kad_post_sidebar_id":"","_kad_post_content_style":"","_kad_post_vertical_padding":"","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"footnotes":""},"categories":[2,69,7],"tags":[24,70],"uagb_featured_image_src":{"full":["https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations.png",468,158,false],"thumbnail":["https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations-150x150.png",150,150,true],"medium":["https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations-300x101.png",300,101,true],"medium_large":["https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations.png",468,158,false],"large":["https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations.png",468,158,false],"1536x1536":["https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations.png",468,158,false],"2048x2048":["https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations.png",468,158,false],"mailpoet_newsletter_max":["https:\/\/thebipower.fr\/wp-content\/uploads\/2020\/05\/Visuals-labels-translations.png",468,158,false]},"uagb_author_info":{"display_name":"Didier TERRIEN","author_link":"https:\/\/thebipower.fr\/index.php\/author\/masterpower\/"},"uagb_comment_info":2,"uagb_excerpt":"Visuals labels translations in Power BI reports are not supported natively. However, there is a trick using conditional formating which does the job. The most used visual labels are titles so I will focus on this kind of label in this post. Steps to translate visuals titles Create a table with the translations including an...","_links":{"self":[{"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/posts\/3024"}],"collection":[{"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/comments?post=3024"}],"version-history":[{"count":26,"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/posts\/3024\/revisions"}],"predecessor-version":[{"id":4367,"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/posts\/3024\/revisions\/4367"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/media\/3037"}],"wp:attachment":[{"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/media?parent=3024"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/categories?post=3024"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/thebipower.fr\/index.php\/wp-json\/wp\/v2\/tags?post=3024"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}