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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Anonymous
Not applicable

How to add custom field format in format pane like Multi KPI

Hi. I really appreciate anyone who can take a look at this. 

 

My question is how to show the enumerationObject in the format pane.
 
I am working on learning how to add custom field formatting in the format pane, just like the Multi KPI example. So I downloaded this visual from github and started to read and test the code. But after I ran sudo pbiviz start, I found the field formatting was blank, as shown in the graph. I didn't do any modification on the original code. But, if I ran sudo pbiviz package and import the packed file to powerbi, the field formatting had something. 

 

The code to add field formatting in the Multi KPI example:

 

public enumerateObjectInstancesWithSelectionId(
        options: powerbi.EnumerateVisualObjectInstancesOptions,
        displayName: string,
        selectionId: powerbi.visuals.ISelectionId,
        enumerationObject: powerbi.VisualObjectInstanceEnumerationObject = {
            containers: [],
            instances: [],
        },
    😞 powerbi.VisualObjectInstanceEnumerationObject {
        
        if (this.areOptionsValid(options)) {
            const { objectName } = options;

            const selector: powerbi.data.Selector = selectionId && selectionId.getSelector();

            this.addSettingsToContainer(
                objectName,
                displayName,
                ColorHelper.normalizeSelector(selector),
                enumerationObject,
                this.getSettings(this[objectName]),
            );
        }
        return enumerationObject;
    }
 

 

 

 Get blank field formatting after running pbiviz start:

Screen-Shot-2020-06-20-at-1.28.07-PM


Non-blank field formatting after importing the packed file

Screen-Shot-2020-06-20-at-1.28.38-PM

1 REPLY 1
dm-p
Super User
Super User

Hi @Anonymous,

Unfortunately this can't be done at present. The MS visuals have some special kind of allowance that makes the drop down work correctly and either building them locally or trying to create your own doesn't work the same way. 

There's an issue open in the GitHub project for this and currently has no ETA. A few of us have been waiting some time for it 😞

Not the answer you were hoping for, I'm sure, but might at least confirm you were thinking along the right lines... just not something that's actually fully implemented in the SDK...

Regards,

Daniel





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!


On how to ask a technical question, if you really want an answer (courtesy of SQLBI)




Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors