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
Hugo_Gallardo
Helper I
Helper I

Power BI Embedded : Cant doCross Filtering selecting multiple rows on a table visual pressing CTRL

Hello I have the following problem:

 

We have embedded different visuals from a PBIX file onto a asp.net core razor view.

 

We have achieved that when a user clicks on a row in a table visual, detect the item and corssfilter the other embedded visuals as the user clicks.

 

On the Power BI environment you can do the same, but by pressing the CTRL key, you can select multiple rows and then it will filter the whole visuals on that page.

 

As we achieved the crossfiltering selecting just one we thought it would do the same by pressing CTRL, the problem is that PowerBI Embedded  visual is not detecting the CTRL key and it is not actually detecting that we are selecting more than one row and it changes the whole filters to the first selected row.

 

We are detecting via JS the CTRL key

Hugo_Gallardo_0-1645732849614.png

After we click in more than one row or item, the event is lost and we can't get the list that the user was selecting:

 

Hugo_Gallardo_1-1645732908822.png

We have tried the following without results:

 

a)

1. document.addEventListener('keydown', function(event) {
console.log(event.key);
}, false);

 

b)

document.addEventListener('keydown', prueba);

function prueba(e) {
console.log(e.KeyCode);
}

 

c)

Hugo_Gallardo_2-1645733077481.png

$("#Tb3").keypress(function() {
console.log( "Handler for .keypress() called." );
});



d)

 

Hugo_Gallardo_3-1645733146186.png

 

 



e) 

$(document).bind("keyup keydown", function(e){
console.log(e);
});

 

 

Do you have any suggestion to help us achieve our goal? 



 

 

 

 

3 REPLIES 3
abner
New Member

Hi @Anonymous 

 

I have tried in the following way, as you propose, but without success

 

abner_0-1646171782924.png

 

With the dataSelected event I can't get the Ctrl event

 

abner_1-1646172057109.png

 

 

Anonymous
Not applicable

Hi @Hugo_Gallardo ,

Please review the following links, hope they can help you.

codesamples.js 

yingyinr_0-1646033922341.png

dataselection.js

How to handle events

report: models.IReport
 page: models.IPage
 visual: models.IVisual
 filters: IFilter[]
 dataPoints: IIdentityValue[]

Best Regards

I have tried in the following way, as you propose, but without success

 

Hugo_Gallardo_0-1648760836199.png

 

 

With the dataSelected event I can't get the Ctrl event

 

Hugo_Gallardo_1-1648760836179.png

 

 

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.