Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Thu Dec 10, 2020 7:44 am

Hello. Spire doesn't apply style "border-collapse: collapse;" to table. As result, content in table has little padding.

Code: Select all
<html class="no-js">
   <head>
      <meta charset="utf-8" />
      <meta http-equiv="x-ua-compatible" content="ie=edge">    <meta name="viewport" content="width=device-width, initial-scale=1" />
      <style>
         .document { font-family: Arial, Helvetica, sans-serif; font-size: 10pt; }
         .text-right { text-align: right; }
      </style>
   </head>
   <body>
      <div class="text-justify document">
         <p>
            Lorem Ipsum is simply dummy text of the printing and typesetting industry.
         </p>
         <table class="document" style="width: 100%; border-spacing: 0; border-collapse: collapse;">
            <tr>
               <td>
                  Lorem Ipsum has been the industrys standard dummy text ever since the 1500s
               </td>
               <td class="text-right">
                  Who
               </td>
            </tr>
         </table>
      </div>
   </body>
</html>

IgorSukhov
 
Posts: 6
Joined: Tue Mar 10, 2020 12:21 am

Thu Dec 10, 2020 10:06 am

Hello,

Thanks for your inquiry.
You want to convert the html to Word document, right? Our Spire.Doc is based on Microsoft Word. And I tried to use our Spire.Doc and Microsoft Word to convert your html into a Word document, but found that the results generated by both are similar, as shown below. What is the style issue you are referring to? Could you provide some screenshots to help us better understand your issue?
453334B6-F5BD-4f94-B2A1-EFDB2697235D.png

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Thu Dec 17, 2020 6:08 am

Hello,

How is your issue now? Could you please give us some feedback at your convenience?

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Return to Spire.Doc

cron