Click here to Skip to main content
15,895,799 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
C#
StringBuilder text = new StringBuilder();
            PdfReader pdfReader = new PdfReader(pdfFile);
            for (int page = 1; page <= pdfReader.NumberOfPages; page++)
            {
                ITextExtractionStrategy strategy = new SimpleTextExtractionStrategy();
                string currentText = PdfTextExtractor.GetTextFromPage(pdfReader, page, strategy);
                text.Append(System.Environment.NewLine);
                text.Append("\n Page Number:" + page);
                text.Append(System.Environment.NewLine);
                currentText = Encoding.UTF8.GetString(ASCIIEncoding.Convert(Encoding.Default, Encoding.UTF8, Encoding.Default.GetBytes(currentText)));
                text.Append(currentText);
                pdfReader.Close();
 

            }
            richTextBox1.Text += text.ToString();




I use this code but it comes continually one after sentence i want to represent the continue two whitespaces can represent as comma(,) plz help some one
Posted
Updated 5-Oct-15 20:03pm
v3

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