web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Why my table not showi...
Power Automate
Unanswered

Why my table not showing perfectly

(1) ShareShare
ReportReport
Posted on by

Hi, Im using compose to convert data from my power apps to power platform. But the table seem distorted. I have attached the sample of the PDF that were generate.

Kindly advise me what should I do.

 

<html>
<head>
<title>Employee Data</title>
<style>
body {
font-family: Arial, sans-serif;
}
table {
width: 100%;
border-collapse: collapse;
background-color: #EEEEEE;
margin-bottom: 20px;
}
table, th, td {
border: 1px solid #1C6EA4;
}
table thead {
background-color: #1C6EA4;
color: #FFFFFF;
}
table thead th {
padding: 10px;
font-size: 15px;
border-left: 2px solid #D0E4F5;
}
table thead th:first-child {
border-left: none;
}
table tbody td {
padding: 8px;
font-size: 13px;
border: 1px solid #AAAAAA;
}
</style>
</head>
<body>
<h2>Employee Data</h2>
<table>
<thead>
<tr>
<th>ID</th>
<th>Employee ID</th>
<th>Department</th>
<th>Project</th>
<th>Site</th>
<th>Grade</th>
<th>Hours</th>
<th>Reasons</th>
<th>Status</th>
<th>Manager</th>
<th>Admin</th>
</tr>
</thead>
<tbody>
<!-- Repeat this <tr> block for each employee's data -->
<tr>
<td>@{items('Apply_to_each')?['ID']}</td>
<td>@{items('Apply_to_each')?['EmployeeID']}</td>
<td>@{items('Apply_to_each')?['Department']}</td>
<td>@{items('Apply_to_each')?['Project']}</td>
<td>@{items('Apply_to_each')?['Site']}</td>
<td>@{items('Apply_to_each')?['Grade/Value']}</td>
<td>@{items('Apply_to_each')?['Hours']}</td>
<td>@{items('Apply_to_each')?['Reasons']}</td>
<td>@{items('Apply_to_each')?['Status/Value']}</td>
<td>@{items('Apply_to_each')?['Manager/DisplayName']}</td>
<td>@{items('Apply_to_each')?['Admin/DisplayName']}</td>
</tr>
</tbody>
</table>
</body>
</html>

MuhamadLai99_0-1720493412052.png

 

Categories:
I have the same question (0)
  • SanmeshG Profile Picture
    1,947 Moderator on at

    Hi @MuhamadLai99  ,


    What is the issue that you are facing ?

     

    I ran your code and created  a PDF by passing some dummy values and it seems to be working fine.

     

    Can you post the error that your getting or the PDF if that is breaking for you ? You can also try re-writing  the HTML with by using inline styling. (You can use chat-gpt for it)

     

    PDF Generated  from the above code,

     

    SanmeshG_0-1720506097864.png

     

    If this helps , do give this a thumbs up and mark this as a solution.

     

    Thanks,

    Sanmesh

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
trice602 Profile Picture

trice602 237 Super User 2026 Season 1

#2
David_MA Profile Picture

David_MA 173 Super User 2026 Season 1

#3
Kalathiya Profile Picture

Kalathiya 95 Super User 2026 Season 1

Last 30 days Overall leaderboard