Click here to Skip to main content
15,913,467 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
iam using mvc4 and razorpdf to convert my view to pdf,everthing working fine but css classes what am using is not applying to pdf,is there any solution for this..
Posted

Of course CSS is not applied to PDF, so you need to format each piece of document individually. Probably you need to parse and analyze CSS. You should clearly understand the difference between PDF and documents like HTML, Open XML and more. In a way, creation of PDF is a one-way process: it is created once and not further supported; normally, this is only an output. Besides, you cannot map flexible and fluid HTML to rigid PDF which is more like a bunch of sheets of paper of fixed size.

—SA
 
Share this answer
 
apply inside style tag i.e. inline css
 
Share this answer
 

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