*** Urgent help required *** Getting exceptions "At most 4 elements (for any collection) can be viewed in evaluation mode" with Aspose PDF temporary license

Hi Team,

Conversion from PDF to PNG failed in production instance for 20 documents with the below mentioned exception while using the temporary license (PO71348325).
However, the same 20 documents were successfully converted/processed when we reverted back that temporary license with old license.

Note – Even though temporary license could not convert 20 documents, the same temporary license could successfully convert other 10 documents.
Hence, the mentioned exception might not be because of incorrect deployment/initialization of the temporary license.

Could you please clarify why few documents could be converted by old license and could not be converted by temporary license.
Currently, we have reverted back old license in production (because only old license able to convert all documents) and the old license is expiring tomorrow.
Hence, could you please help us to fix this issue as soon as possible ?

Exception with temporary license

[ERROR][MpoIncomingOperation] PNG conversion failed: At most 4 elements (for any collection) can be viewed in evaluation mode.
class com.aspose.pdf.exceptions.IndexOutOfRangeException: At most 4 elements (for any collection) can be viewed in evaluation mode.
com.aspose.pdf.ADocument.m2(Unknown Source)
com.aspose.pdf.PageCollection.m1(Unknown Source)
com.aspose.pdf.PageCollection.get_Item(Unknown Source)
com.db.dcf.docs.opsrunner.processor.DefaultOperationsProcessor.processMessage(Unknown Source)
com.db.dcf.docs.opsrunner.processor.DefaultOperationsProcessor.process(Unknown Source)
at com.aspose.pdf.ADocument.m2(Unknown Source)
at com.aspose.pdf.PageCollection.m1(Unknown Source)
at com.aspose.pdf.PageCollection.get_Item(Unknown Source)
at com.db.dcf.docs.tgw.util.PdfConversionUtility.pdf2png(PdfConversionUtility.java:169)
at com.db.dcf.docs.faxadapter.operations.incoming.MpoIncomingOperation.savePNG(MpoIncomingOperation.java:273)
at com.db.dcf.docs.faxadapter.operations.incoming.MpoIncomingOperation.processFax(MpoIncomingOperation.java:163)
at com.db.dcf.docs.faxadapter.operations.incoming.MpoIncomingOperation.execute(MpoIncomingOperation.java:70)
at com.db.dcf.docs.opsrunner.processor.DefaultOperationsProcessor.processMessage(Unknown Source)
at com.db.dcf.docs.opsrunner.processor.DefaultOperationsProcessor.process(Unknown Source)
at com.db.dcf.docs.faxadapter.ejb.MpoIncomingMDB.onMessage(MpoIncomingMDB.java:140)
at weblogic.ejb.container.internal.MDListener.execute(MDListener.java:438)
at weblogic.ejb.container.internal.MDListener.transactionalOnMessage(MDListener.java:361)
at weblogic.ejb.container.internal.TokenBasedJMSMessagePoller.processOneMessage(TokenBasedJMSMessagePoller.java:355)
at weblogic.ejb.container.internal.TokenBasedJMSMessagePoller.run(TokenBasedJMSMessagePoller.java:125)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:678)
at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:352)
at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:337)
at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:57)
at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41)
at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:652)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:420)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:360)
[DEBUG][MpoIncomingOperation] ***** FAILED MESSAGE *****

Ramkumar Ramasamy


You can use the old license for as long as you want until you are using it with the API version which was released before its expiry date. Furthermore, it seems like you are using API in a multi-threaded environment. Would you please share a sample console application in .zip format including your license file which is failing. We will test the scenario in our environment and address it accordingly.

You can share the application in a private message by clicking over username and pressing the Blue Message Button.

Hi Asad Ali/Team,

Thanks for your reply.

Need some time to share affected part of our application code to test in your environment.

Our current license Subscription expiry date is 10 March 2021.

Do you mean we can still use that license after 10 March 2021 with the APIs available with that version of the license ?

If yes, how many days that current license will work.

If not, (if that license can not be used after 10 March 2021), is there any way we can get a grace period for one or two weeks to use the same license ?


Hi Team,

Apart from the clarification we have asked regarding Subscription expiry date, could you answer below 2 questions ?

Question 1 - The error says “At most 4 elements (for any collection) can be viewed in evaluation mode”. Does the word “evaluation mode” in the error message refers the temporary license ? If not, could you please confirm when an Aspose related program will raise such exception ?


  1. The exception raised from Aspose class

  2. Our application could process (or the Document.getPages() method worked fine) for all the documents with less than or equal to 4 pages using the temporary license. But, all the documents with more than 4 pages were failed with the mentioned error.

Question 2 - Could you please confirm whether Edition Type in the temporary license can be either ‘Professional’ or 'Enterprise’ ? Because, the temporary license file we have received during last year and also all other permanent licenses we received earlier had Edition Type as 'Enterprise’. And only the concerned temporary license we received now have Edition Type as ‘Professional’.

As old license expiring today need your quick help in fixing issue we got with temporary license.



In case your license is being expired today (10 March 2021), you would not be able to use it with the API versions released after today e.g. 21.3, 21.4, etc. In other words, you can still use it with 21.2 version of the API which was released before the license expiry date.

Please note that - as shared earlier - you can use your license for as long as you want until you are using it with the API version which was released before the date of expiry. In simple words, you can keep using the license with 21.2 version of Aspose.PDF for Java for as long as you want and you would not need any grace period as the license file would keep working.

You would be needing to upgrade the license if you decide to upgrade API version to 21.3 or higher because your current license would not support these versions. Please also take into account that the latest available version of the API is 21.2 at the moment and your current license is valid with it. Next API update will be released at the end of this month and you can upgrade your license as well if you decide to use the next version(s).

The exception is raised when you use the API without any license (in trial mode). The temporary license acts as a valid license except it limits the usage for 30-days only. So, you should not be facing the evaluation mode exception while using the temporary license. There could be different reasons if you are facing it. Either the license is not being set correctly (due to multi-threaded environment) or the license file is not being included in the project correctly.

Please try to create a simple console application and use your temporary license in it to carry out PDF(more than 4 pages) to Image or any functionality and see if same exception occurs. Then, share that application with us in .zip format.

Regarding your above question, the edition type in the license should not be any issue. Please try to follow the suggestions given in previous paragraph and let us know about your feedback.

Hi Team,

We have written simple program and we could reproduce the same exception with the temporary professional license.

With the temporary license, the program is able to convert documents to PNG if it has less than or equal to 4 pages. If the document have more than 4 pages, the program throws the same exception.

DB restricts us from sharing files online. Hence, could you please provide us the mailbox where the files can be shared?

We have also validated that if the SubscriptionExpiry date of the current license is changed to any past date, the same exception is thrown.


Hello Asad / team,

Please can we prioritize this issue. The core application which uses this license is a critical one and functional issue such as this one would lead to production outage, if not resolved in time.

Please provide with a mailbox where the temp sample program can be shared with you, for you to look into and investigate. In the interim, it would help if you could provide with a temporary Enterprise license so that we can test out.

  • With the existing license, and with the API version unchanged at 21.2, the application at its test environment has been found not to be working (with expiry date in past, or with a future date).

  • With the temporary Professional license, “[ERROR][MpoIncomingOperation] PNG conversion failed: At most 4 elements (for any collection) can be viewed in evaluation mode” has been encountered.

  • As Ram stated above, even with a sample test application, the error continues.

This is not about any issue with the license file’s installation or placement, nor due to “multi-threaded environment” (we do not have any here).

Can we get into a call to discuss further please?



We have sent you a private message to share the files with us. Please check your inbox and reply to it with requested information. Furthermore, please also clarify that why you are trying to use 21.2 version with a temporary license if you already have a valid license that is supported by it?

Hi Asad,

I have responded back to you on your email.

Please have a look.


Hi Team,

We have obtained new permanent license (OrderID - 210216085846, SubscriptionExpiry - 20220310, EditionType - Professional).

But, even with that new permanent license and with the latest jar - aspose.pdf-21.2.jar, we are getting the same below mentioned Evaluation mode exception in our production instance. This exception happens while processing few documents. i.e, while calling com.aspose.pdf.PageCollection.get_Item method for few documents.

[ERROR][MpoIncomingOperation] PNG conversion failed: At most 4 elements (for any collection) can be viewed in evaluation mode.

Note - We have also confirmed that there is no conflict in the Aspose licenses in the production instance. And our log shows that new license is loaded. But, still the error continues while processing few documents.

Could you please suggest us how can we find out the root cause for this issue ?



Thanks for sharing the license file in a private message.

We have tested your license file and used it to convert a 80 Pages PDF document into PNGs with Aspose.PDF for Java 21.2. We did not notice any issue or exception at our end in a console application. The API generated images for all PDF pages without throwing any exception.

Since, you were able to reproduce the issue at your end in a simple program, please share that console application in .zip format with us without modifying its code. Also, please share one of the sample PDFs with which API is raising issue at your side. We will again test the scenario in our environment and share our feedback with you.

You may please share the requested files in the same private message thread where you have shared the license file already.


We tested the application which you have shared using both temporary and permanent licenses with Aspose.PDF for Java 21.2. As per our findings:

  • No issue occurred with the permanent license when loading from the resource (permanentlicense.png)
  • No issue occurred with the permanent license when loading from the file path (licenseloadingfrompath.png)
  • An evaluation mode exception is thrown when loading Temporary License from both resources and file path

It seems like the temporary license file is corrupted/modified or invalid. Please try to apply for another temporary license and test again. In case you still notice the same issue, please share the license file with us here. We will again test the scenario in our environment and address it accordingly.