Can we extract pdf Paragraph by Paragraph

Can we extract pdf Paragraph by Paragraph

@kranthireddyr,

Please try the following code example:

[C#]

Document doc = new Document(dataDir + "amblatt2013-10-05.pdf");
ParagraphAbsorber absorber = new ParagraphAbsorber();
absorber.Visit(doc);

foreach (PageMarkup markup in absorber.PageMarkups)
{
    int i = 1;
    foreach (MarkupSection section in markup.Sections)
    {
        int j = 1;
        foreach (MarkupParagraph paragraph in section.Paragraphs)
        {
            StringBuilder paragraphText = new StringBuilder();

            foreach (List<TextFragment> line in paragraph.Lines)
            {
                foreach (TextFragment fragment in line)
                {
                    paragraphText.Append(fragment.Text);
                }
                paragraphText.Append("\r\n");
            }
            paragraphText.Append("\r\n");
            Console.WriteLine("Paragraph {0} of section {1} on page {2}:", j, i, markup.Number);
            Console.WriteLine(paragraphText.ToString());
            j++;
        }
        i++;
    }
}

Not able to get ParagraphAbsorber class from my dll.

@kranthireddyr,

Please download and try the latest version 18.1 of Aspose.Pdf for .NET API.