cancel
Showing results for 
Search instead for 
Did you mean: 

Email Sender Snap Include two different table

ash42
New Contributor III

This is some part of html code that I m using to include in Email body

'

<tr>

    <th>Description</th>

    <th>Record Count</th>

  

  </tr>

  <tr>

    <td>Total Record Count In File</td>

    <td>'+ _Rowcount + '</td>

      </tr>



        </table> 

        <br/><br/>

        Total Successful Record Count In File :' +  _ValidRecords+'<br>

        Total Error Record Count In File :'+ _InvalidRecords+'

        

        <br>Error Records Description<br><br>

    <table  class="hovertable"> 

    </table>'

Here first table is just a table with 1 row with static values and for the second table tag rows will be populated from input document.
This is working ok,but the issue i am facing is both the table are sticking together even if i have defined them separately in html code. Also the text expected above the second table is also pushed down. refer screenshot below:

image

…I ran the same html code in my local browser and was getting expected results(Two separate tables)

image

Is there any fix for this,so that i get two separate tables

4 REPLIES 4

marjan_karafilo
Contributor

Hello @ash42 ,

Are you able to apply CSS to the tables?
If yes, you can use the margin attribute on them.

Regards,
Marjan

yes…also have given two separate style class which is working fine as given in 2nd image but not not in snaplogic emailbody

Hi,

Email Sender snap has the ability to style the HTML in the body.

image

Here is an example.

Regards,
Marjan

ya was already using the same

'

<head> 

     <title>Email Snap HTML Table</title> 

<style type="text/css"> table.Snap {background-color:transparent;border-collapse:separate;width:100%;margin-bottom: 10px;} table.Snap th, 

      table.Snap td {text-align:center;border:1px solid black;padding:5px;} table.Snap th {background-color:AntiqueWhite;} 

      table.hovertable {font-family: verdana,arial,sans-serif;font-size:11px;color:#333333;border-width: 1px;border-color: #999999;border-collapse: separate;}table.hovertable th {background-color:#c3dde0;border-width: 1px;padding: 8px;border-style: solid;border-color: #a9c6c9;}table.hovertable tr{background-color:#d4e3e5;}table.hovertable td {border-width: 1px;padding: 8px;border-style: solid;border-color: #a9c6c9;}

      

</style>



</head> 

<body> ' +

'<b>MTM Audit Canvas Offer File Load Package execution is partially successful and ' + _filename + ' file is processed but some error records were found in the file.</b><br/><br/>' + 

    

 '<table class="Snap"> 

<tr>

    <th>Description</th>

    <th>Record Count</th>

  

  </tr>

  <tr>

    <td>Total Record Count In File</td>

    <td>'+ _Rowcount + '</td>

      </tr>



        </table> 

        <br/><br/>

        Total Successful Record Count In File :' +  _ValidRecords+'<br>

        Total Error Record Count In File :'+ _InvalidRecords+'

        

        <br>Error Records Description<br><br>

    <table  class="hovertable"> 

    </table>

        '+

        ' <font size=3><b>SSIS package Name :: </b>' + _ProcessName + '.dtsx </font></br></br> '+

            ' <p><b><font size=3>Executed On ::  </b>' +  Date.now().toLocaleDateString()  + '</font></p> 

             <p><b><font size=3>Execution Machine :: </b>'+ 'System::MachineName' + '</font></p> 

             <p><b><font size=3>Executed By :: </b>"'+ pipe.user + 

 '<p><font size=3>Inspire Canvas Offer Archive File :: '+ 'FTPArchiveDirectoryForMailInvalidFile' + 'FTPArchiveFileName'+ ' </font></p> 

            

             <br><font size=3> This is a system generated email. Please do not Reply.</font></p>

             <b><font size=3> IT System Notification</font></p>

</body> 

</html>'