Reading PDF per Line

前端 未结 4 945
南方客
南方客 2021-01-13 09:20

How can I read a PDF file line by line using iText5 for .NET? I have search through the internet but I only found reading PDF file per page content.

Ple

4条回答
  •  北海茫月
    2021-01-13 09:47

    Try this, use theLocationTextExtractionStrategy instead of the SimpleTextExtractionStrategy it will add new line characters to the text returned. Then you can use strText.Split('\n') to split your text into a string[] and consume it on a per line basis.

提交回复
热议问题