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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Natia
Frequent Visitor

Group the data by semesters in HTML & CSS viewer in Power BI

Hello everyone, I need your help.

I downloaded HTML & CSS viewer in Power BI Desktop and I try to write a DAX code in it. 
I can write a code for semesters and for courses separately but I could not put the courses according to their semesters to show what courses a student have passed in concrete semester. 

I could reach only this visual at this moment using these formulas below:

 

 <tr >
    <td>Course Name</td>
    "& CONCATENATEX(DISTINCT('Courses'[Semester ID ]), "<tr> <td ></td> <td align='center'>"& 'Courses'[Semester ID ],,'Courses'[Semester ID ],ASC)&"
    "&CONCATENATEX(FILTER('Courses','Courses'[Semester ID ]='Courses'[Semester ID ]),"<tr> <td ></td>  <td align='center'>"& 'Courses'[Course Name ] &"</td> </tr>","",'Courses'[Semester ID ],ASC) &"
  </tr>
 

Natia_0-1682414190175.png

I want to achieve this result instead of visual I created above: 
 
 
Natia_2-1682414213352.png

 

If it is not enough information here, I can send you a Powe BI example file with mail.

Thank you so much in advance, 

2 REPLIES 2
lbendlin
Super User
Super User

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.

https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523

Thank you for your replying,

This is working example file:

https://drive.google.com/file/d/1ufv1gLffwnK2KQXoh9imoh3e5z7knP8J/view?usp=sharing

I need to sort students subjects by passed semesters.

what I made is:

irinabazghadze_0-1682854808813.png

 

 

but i need semester id 38 in group (when subject is several).

So, My goal is to achive this result:

irinabazghadze_1-1682854808815.png

 

this task is very important for us.

thank you for your attention

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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