Quantcast
Channel: Aspose.Pdf Product Family
Viewing all articles
Browse latest Browse all 3131

Object reference not set to an instance of an object

$
0
0
Hi,

I am using aspose.pdf to create text file from PDF files. The code below, works fine for majority of my PDF files, but it gives me an exception for one PDF.

Dim objLicensa As New Aspose.Pdf.License()
objLicensa.SetLicense("c:\OutSell\Programas\Aspose.Pdf_1160.lic.xml")
Dim objPdfDocument As New Aspose.Pdf.Document(varNomeArquivoPDF, EncodingType.UTF8)
Dim objAbsorber As New Aspose.Pdf.Text.TextAbsorber()
objPdfDocument.Pages.Accept(objAbsorber)
Dim objExtractedText As String = objAbsorber.Text


Stack is:


System.NullReferenceException was caught
Message=ReferÍncia de objeto n„o definida para uma inst‚ncia de um objeto.
Source=Aspose.Pdf
StackTrace:
em Aspose.Pdf.PageCollection.Accept(TextAbsorber visitor)
em OutSellGerente.os3.funConvertePDF2Text(String varNomeArquivoPDF, String varNomeArquivoTXT) na C:\Users\Henrique\Documents\Visual Studio 2010\Projects\OutSellGerente\os3.vb:linha 10725
InnerException:

Viewing all articles
Browse latest Browse all 3131

Trending Articles