Forum Discussion
Some SVG codes not running on Power BI
- 7 years ago
Hi Snandy,
Please download the demo from the attachment.
The only difference between the 1 and the 2 is the blue part in the code below. If you'd like to show them in a Table visual, you need to change the "Data category" to "Image URL".
data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height='500' width='500' fill = 'Green'><polygon points='250,60 100,400 400,400' /><animateMotion path='M 20 20 V 50 Z' dur='3s' repeatCount='indefinite'/></svg>
Best Regards,
Dale
This SVG code works fine for me, however the first string is not needed you only need the part inbetween the SVG tags.
Have you read this series of blog posts on SVG images in Power BI?
https://dataveld.com/2018/01/13/use-svg-images-in-power-bi-part-1/
https://dataveld.com/2018/01/15/use-svg-images-in-power-bi-part-2/
https://dataveld.com/2018/07/16/use-svg-images-in-power-bi-part-3/
Edit: you need to have the data in columns for the HTML viewer to work, measures do not work in my experiance.