Using ASPOSE CELLS v5.3.2.2
I’m trying to save an Excel WorkBook as a PDF file, using the Save method :
Dim excelFile As Aspose.Cells.Workbook = NothingThe Application pool identity are defined as “Network Service” on both site.
excelFile = New Workbook(inExcelFilePath)
excelFile.Save(outPdfFilePath, SaveFormat.Pdf)
During the Call of the Save method, the process in stopped with the Exception :
System.IndexOutOfRangeException: Index was outside the bounds of the array.
at Aspose.Cells.?.?(String ?)
at Aspose.Cells.?.?(Worksheet ?, Cell ?, FormatCondition ?, ? ?)
at Aspose.Cells.?.?(Worksheet ?, Cell ?)
at Aspose.Cells.?.?(Worksheet ?, Cell ?, Style ?, Boolean ?, Style& ?)
at Aspose.Cells.Pdf.?.?(Int32 ?, Int32 ?, Int32 ?, Int32 ?, Int32 ?, Int32 ?)
at Aspose.Cells.Pdf.?.?(Int32 ?, Int32 ?, Int32 ?, Int32 ?, Int32 ?)
at Aspose.Cells.Pdf.?.?(XmlNode ?, Int32 ?, Int32 ?, Int32 ?, Int32 ?, Int32 ?)
at Aspose.Cells.Pdf.?.?(XmlNode ?, ? ?)
at Aspose.Cells.Pdf.?.?(XmlNode ?, XmlNode& ?, ? ?)
at Aspose.Cells.Pdf.?.?(CellArea ?, Boolean ?, XmlNode ?)
at Aspose.Cells.Pdf.?.?(XmlNode ?, Int32 ?)
at Aspose.Cells.Pdf.?.?()
at Aspose.Cells.Pdf.?.?(Stream ?)
at Aspose.Cells.Workbook.Save(Stream stream, FileFormatType fileFormatType)
at Cnr.Inari.SVC.IO.Pdf.PDFHelperAspose.ExcelToPdf(String inExcelFilePath, String outPdfFilePath, Boolean calculateFormula) in E:\Temp\CRI_INA_INARI\Main\Sources\Main\Source\INARI-SVC\IO\PDFHelperAspose.vb:line 62
at Cnr.Inari.BLL.Entities.Message.EnvoyerVers(String exchangeWSUrl, String exchangeMailBox, String exchangeUser, String exchangePassword, String exchangeDomaine, Boolean isOwner, String to, String attachment, String body) in E:\Temp\CRI_INA_INARI\Main\Sources\Main\Source\INARI-BLL\Entities\Message.vb:line 284
at Cnr.Inari.BLL.Entities.Mail.Envoyer(String exchangeWSUrl, String exchangeMailBox, String exchangeUser, String exchangePassword, String exchangeDomaine, Boolean isOwner, String attachment, String bodyUrl, String adressPattern) in E:\Temp\CRI_INA_INARI\Main\Sources\Main\Source\INARI-BLL\Entities\Mail.vb:line 66
at Cnr.Inari.AlertesUC.AcquitterMessages(Boolean envoi) in E:\Temp\CRI_INA_INARI\Main\Sources\Main\Source\INARI\Composants\AlertesUC.ascx.vb:line 350
What is very strange is that this application is installed on 2 IIS web server who are redundant with a load balancer.
The configuration are exactly the same
On the first server, the save method works fine…
On the second one, the save method failed with the error given above
We remarqued that if we put the pool identity as “Local System” on the server where we got the error, then, it works fine !
Any idea about what can be wrong ?
thanks