This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreLevel up your Power BI skills this month - build one visual each week and tell better stories with data! Get started
Hey guys,
I'm trying to get formatting objects for rows in a table dataView.
First, I create a row selector and add it to the transformed model.
let eventSelection = this.host.createSelectionIdBuilder()
.withTable(tableDataView, j)
.createSelectionId();
Also I create colors for each selected row:
let color;
if(this.sett.colors.autoColor.value) {
color = colors[j];
} else if(this.sett.colors.isSingleColor.value) {
color = this.sett.colors.defaultColor.value;
} else if(tableDataView.rows[j].objects) {
color = tableDataView.rows[j].objects["colors"]["eventColor"]["solid"]["color"]
} else {
color = colors[j]
}
let ids;
roles.forEach(r=> {
let role = r.role;
if(role == "events") {
let val = tableDataView.rows[j][r.index];
ids = {"selection": eventSelection, "event": val, "color": color};
}
})
dv.id.push(ids);
Then, I populate the enumerateObjectInstances format bar in the following way:
case 'colors':
if(this.allData) {
for(let row of this.allData.id) {
properties.push({
objectName: propertyGroupName,
displayName: row.event,
properties: {
eventColor: row.color
},
selector: row.selection.getSelector()
})
}
}
break;
The formatting options appear fine, I take the values of the rows of one of the columns as the displayed values.
The problem is that when choosing a color for my "rows" I don't see these objects in the dataView. That is, I assume that they should appear somewhere here -
tableDataView.rows[i].objectsbut there is nothing there.
The selectors show the correct identityIndex , but there are no objects in the model for them.
dataView
Formating panel:
Check out the April 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.