Forum Discussion
Different Behaviour of Custom Visual in Power BI Service and Desktop
- 9 years ago
You should use getFormatStringByColumn method to get a correct type that has been specified by Power BI Desktop.
I'd recommend that you should use valueFormatter to format values.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
- 9 years ago
Hello v-mubish,
Could you please install @types/d3@3.5.36 (npm i @types/[email protected] --save) and try to build the visual again?
Please pay attention to the fact that you should execute all of commands in the visual's directory.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
Hello v-mubish,
Does Power BI Desktop return correct types? Do you use formatting-utils to format values?
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
- v-mubish9 years ago
Helper I
Hi v-viig,
I am not using any formatting utility like formatting-utils or any other, and powerBI shows data type "whole number" for each column except date/time column i.e. "Hour".
One thing i observed, when we are changing type or format from modelling pane in PBI Desktop, that format is getting reflected in built-in table visual. But these changes when I am doing, are not getting reflected in my Custom visual.
How to reslove this?
- v-viig9 years ago
Community Champion
You should use getFormatStringByColumn method to get a correct type that has been specified by Power BI Desktop.
I'd recommend that you should use valueFormatter to format values.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
- v-mubish9 years ago
Helper I
Hi v-viig,
I am trying to install "FormattingUtils" set that u suggested. I followed the steps for formattingUtils installation.
after that, Getting this error while trying to run the visual by using "pbiviz start".
need help!!
Note-: I have followed all the steps mentioned in this link.