Hi,
I copied the dll to bin folder and then the code works. But it cannot
retrieve the text as desired. I want to extract text from PDF but failed. Does your product
<span style=“font-size:12.0pt;font-family:“Times New Roman”,“serif”;mso-fareast-font-family:
Calibri;mso-fareast-theme-font:minor-latin;mso-ansi-language:EN-US;mso-fareast-language:
EN-US;mso-bidi-language:AR-SA”>extract it. If yes then let us know.
Document pdfDocument = new Document(@"C:\AA\Maval_Puravani2\Test\A2050015.pdf");
//create TextAbsorber object to extract text
TextAbsorber textAbsorber = new TextAbsorber();
//accept the absorber for all the pages
pdfDocument.Pages.Accept(textAbsorber);
//get the extracted text
string extractedText = textAbsorber.Text;
// create a writer and open the file
TextWriter tw = new StreamWriter(@"C:\AA\Maval_Puravani2\Test\extracted-text.txt");
// write a line of text to the file
tw.WriteLine(extractedText);
// close the stream
tw.Close();
This gives output as following
Evaluation Only. Created with Aspose.Pdf.
So I cannot test if your component extracts correct text from the PDF.
thx,
M.Irfan.