iTextsharp landscape document

前端 未结 2 1990
粉色の甜心
粉色の甜心 2020-12-29 05:00

I am trying to create Landscape PDF using iTextSharp but It is still showing portrait. I am using following code with rotate:

Document document = new Documen         


        
2条回答
  •  一生所求
    2020-12-29 05:39

    No need to initialize the Document and reset the page size...

    Document doc = new Document(iTextSharp.text.PageSize.A4.Rotate(), 10, 10, 10, 10);
    

    ...will do the trick.

    (4.1.6.0)

提交回复
热议问题