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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
ferryv
Resolver II
Resolver II

Data Color issue - custom visual barChart

I copied the source from the github repo and used pbiviz package to  package the file and import the visual in powerbi desktop with the aim to see if it all works.

 

owever, when opening the Data Colors tab, only the color on the last column can be updated. Has anyone seen this before or reported this? 

 

ferryv_0-1704728929065.png

 

 

1 ACCEPTED SOLUTION

Thanks. Was trying to get the barChart github files to work properly to understand what happened.

 

Managed to resolve it by:

- rerunning: npm i -g powerbi-visuals-tools@latest and npm i d3@latest --save to get the latest libraries

- setting up a new project using pbiviz new barChart

- copying the files from the github repo (https://github.com/microsoft/PowerBI-visuals-sampleBarChart) in the new barChart folder (incl replacing existing ones)

- change the version in pbiviz.json from  "version": "4.0.0" to  "version": "4.0.0.0" as an error occurred (version should be in 4 parts) with the latest libraries

- installed Microsoft Power BI visuals TooltipUtils (as this was missing) via npm i powerbi-visuals-utils-tooltiputils

 

When packaging the file via pbiviz package and importing it in PowerBI Desktop, it worked fine.

 

ferryv_0-1705068647542.png

 

 

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi  @ferryv,

Thanks for reaching out to us with your problem. Based on your description, it seems that you are encountering a problem where only the last column's color can be updated in the Data Colors tab for a custom visual that you imported from a GitHub repository. You can refer the following official documentation to build a bar chart.

Build a bar chart visual in Power BI - Power BI | Microsoft Learn

In addition, you can refer the following link to debug the problem to make troubleshooting.

How to debug Power BI custom visuals - Power BI | Microsoft Learn

Best Regards

 

Thanks. Was trying to get the barChart github files to work properly to understand what happened.

 

Managed to resolve it by:

- rerunning: npm i -g powerbi-visuals-tools@latest and npm i d3@latest --save to get the latest libraries

- setting up a new project using pbiviz new barChart

- copying the files from the github repo (https://github.com/microsoft/PowerBI-visuals-sampleBarChart) in the new barChart folder (incl replacing existing ones)

- change the version in pbiviz.json from  "version": "4.0.0" to  "version": "4.0.0.0" as an error occurred (version should be in 4 parts) with the latest libraries

- installed Microsoft Power BI visuals TooltipUtils (as this was missing) via npm i powerbi-visuals-utils-tooltiputils

 

When packaging the file via pbiviz package and importing it in PowerBI Desktop, it worked fine.

 

ferryv_0-1705068647542.png

 

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.