The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
How do I get the column headers of a table with the Power BI client javascript api?
I am able to get the datafield name (being "Position Type Name" below) with this method: await visual.getDataFields("Values");
But this method does not seem to return the "overridden" name which is what is shown as column header in the table (being "Name" below):
Eric
Hi, @Eric7
Make sure you're familiar with the latest features and limitations of the Power BI JavaScript API. Sometimes, new features or methods are introduced that may be relevant to your needs.
Power BI embedded analytics overview - Power BI | Microsoft Learn
If the JavaScript API doesn't provide the functionality you need, another approach is to use the Power BI REST API to access dataset and table schema information. For information about the REST API, you can check out the following documentation:
Power BI REST APIs for embedded analytics and automation - Power BI REST API | Microsoft Learn
How to Get Your Question Answered Quickly
Best Regards
Yongkang Hua
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
77 | |
76 | |
36 | |
31 | |
29 |
User | Count |
---|---|
93 | |
79 | |
57 | |
48 | |
48 |