I am trying to concatenate two files and get an error:
An exception of type ‘System.NullReferenceException’ occurred in Aspose.Pdf.dll but was not handled in user code
Additional information: Object reference not set to an instance of an object.
The two files are attached, here is the code snippet:
Public Sub MergePDFs(ByRef SourceFiles() As String, ByRef OutputFile As String)
Dim license As Aspose.Pdf.License = New Aspose.Pdf.License()
license.SetLicense(“MCPSR.Aspose.Pdf.lic”)
license.Embedded = True
Dim pdfEditor As New PdfFileEditor()
With pdfEditor
.AllowConcatenateExceptions = True
.Concatenate(SourceFiles, OutputFile)
End With
End Sub
The issues you have found earlier (filed as PDFNET-41250) have been fixed in Aspose.PDF for .NET 22.3.