cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
dandandsan
Helper II
Helper II

Tables help

Hello,

 

I'm using the code below which is working fine but I would like to add a header to separate the two collections but so far I have only been able to add this for the first collection. When I add a header for the second it's populated in the last row of the last column. 

 

I know this is something pretty straight forward and have tried different combination but am now throwing in the towel. Any help would be much appreciated. 

 

Office365Outlook.SendEmailV2("email","Stock",                                                                                      
"<table width='100%' border='1' cellpadding='5' style='border:1px solid black; border-collapse:collapse'>" &
    "<tr style='background-color:#efefef'>
        <th>Description</th>
        <th>Device</th>
        <th>Current Level</th>
    </tr>" &                                                                                                                                               
Concat(colTonerStock,
    
    "<tr>
            <td>" & Title & " </td>
          <td>" & Device & " </td>
            <td>" & CurrentLevel & " </td>
            </tr>")&                                                                                                                                                                    
"<table width='100%' border='1' cellpadding='5' style='border:1px solid black; border-collapse:collapse'>" &
    "<tr style='background-color:#efefef'>
        <th>Description</th>
        <th>Device</th>
        <th>Current Level</th>
    </tr>" &                                                                                                                                               
Concat(colWasteStock,
    
    "<tr>
            <td>" & Title & " </td>
          <td>" & Device & " </td>
            <td>" & CurrentLevel & " </td>
            </tr>"))

 

1 ACCEPTED SOLUTION

Accepted Solutions
Pstork1
Dual Super User
Dual Super User

I don't believe an HTML table can have two headers.  You could add the header as an additional row between the two collections or split the HTML into two tables with two headers, one for each collection.  Your code below will work, you just need to add a '</Table>' to close off the first table before you start the second one.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

View solution in original post

2 REPLIES 2
Pstork1
Dual Super User
Dual Super User

I don't believe an HTML table can have two headers.  You could add the header as an additional row between the two collections or split the HTML into two tables with two headers, one for each collection.  Your code below will work, you just need to add a '</Table>' to close off the first table before you start the second one.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

@Pstork1 

 

It's as simple as that, thank you!

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Difinity Conference 2022

Difinity Conference 2022

Register today for two amazing days of learning, featuring intensive learning sessions across multiple tracks, led by engaging and dynamic experts.

European SharePoint Conference

European SharePoint Conference

The European SharePoint Conference returns live and in-person November 28-December 1 with 4 Microsoft Keynotes, 9 Tutorials, and 120 Sessions.

Power Apps Ideas

Changes to Ideas Coming

We are excited to announce a new way to share your ideas for Power Apps!

Top Solution Authors
Top Kudoed Authors
Users online (1,889)