Click here to Skip to main content
15,886,518 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
HI

i want to convert html code into pdf as it is.

for exp.. a table made in html , when viewed in browser , shows proper table..
and when i use itextpdf and convert it , then that is not formatted

exp:
HTML
<html><table><tr><td>ddddddddddd</td></tr><tr><td>agsbababasbasbasb</td></tr></table></html>

the above code is just small test code..
i have used table spacing , padding
Posted
v2

1 solution

 
Share this answer
 
Comments
maulikshah1990 7-Mar-14 2:32am    
the above are not exactly what i want..and when i run the code from above link, they generate error

pls provide example with code which is easy to understand
What type of error you see?
maulikshah1990 7-Mar-14 2:51am    
i get error as
Cannot implicitly convert type 'System.Collections.ArrayList' to 'System.Collections.Generic.List<itextsharp.text.ielement>'
Validation Complete
So, it is quite obvious. Please check the code line which causes this issue and correct that.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900