Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

323
Views
How to Get Field Name(Capability Name) from GetFilter Method of powerBi using JavaScript

We are creating Visuals using Power BI API Client(JavaScript).Once it is created I want to pre populate all selected Capabilities and filters in another view.I used Visual.getFilters() method to get all pre selected filters but in each item I am not getting the capability to which it belongs,Is there is any way to get capability name with each filter. for example

I selected bellow properties for creating a visual

Visual Type = Funnel

Capabilities

1 Group = Group1

2 Values = value1

after saving this visual when we execute getFilters(),we are getting this two objects but it does not contains Capability names like Group/Values

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

It is not possible to get the capability names in each filter using getFilters(), we can get the Capability Names by using getCapabilities. To get the capability names, follow the below steps:

  1. Create an authoring page:
window.authoringPage = await report.addPage(pageName);
  1. Create a visual using Create a visual API:
const createVisualResponse = await page.createVisual('Visual_Name');
const visual = createVisualResponse.visual;
  1. Get the applied filters using getFilters():
const filters = await visual.getFilters();

We didn't get capabilities of each filter in filters object

enter image description here

  1. Get the Capability Names by using getCapabilities:
const capabilities = await visual.getCapabilities();

enter image description here

Find the references and the sample code here: https://docs.microsoft.com/javascript/api/overview/powerbi/report-authoring-overview https://docs.microsoft.com/javascript/api/overview/powerbi/create-add-visual https://docs.microsoft.com/javascript/api/overview/powerbi/get-visual-capabilities

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!