We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Null Pointer Exception thrown at com.aspose.email.internal.b.ap.b

Hi,
My code is as follows:
MailMessage message;
message = MailMessage.load(inputFile, MessageFormat.getMsg());
return message;

The following exception is thrown while processing SMIME email:

com.aspose.email.system.exceptions.NullReferenceException: Object reference not set to an instance of an object.
at com.aspose.email.internal.b.ap.b(Unknown Source)
at com.aspose.email.qk.b(Unknown Source)
at com.aspose.email.qk.a(Unknown Source)
at com.aspose.email.qk.interpret(Unknown Source)
at com.aspose.email.MailMessage.b(Unknown Source)
at com.aspose.email.MailMessage.a(Unknown Source)
at com.aspose.email.MailMessage.load(Unknown Source)
at com.aspose.email.client.impl.AsposeApis.getMailMessageFromFile(AsposeApis.java:34)
at com.aspose.email.client.impl.AsposeApis.extractMsgFromFile(AsposeApis.java:199)

I have attached two such emails as example which are throwing the exception.
Could you please look into it?

Thanks,
Ankita
Hi Ankita,

Thank you for sharing your concern with us.

I was able to reproduce this issue at my end using the latest version of Aspose.Email for Java 4.5.0 and have logged it as NETWRKJAVA-33410 in our issue tracking system for further investigation by our development team. Once there is any information available in this regard, I'll update you here via this thread.

We are sorry for the inconvenience caused to you.

Hi Kashif Iqbal,


Do we have any update on this NETWRKJAVA-33410. Previously we used to have different messaging app tool which was processing these kind of emails but now we have upgraded to Aspose which is blocking us from import of SMIME emails.

Thanks,
Ajesh

Hi Ajesh,

I have checked the status of this issue from our issue tracking system and found that the issue has been fixed for the .NET version of this issue. Once the version is ported to Java for release and available for download, we’ll notify you here via this thread.

Hi Kashif Iqbal,


Are you aware of any timeline by which fix will be availbale for JAVA version. We would really appreciate if we can escalate this and try to resolve it faster.

Also is it possible for us to have an early release for just testing purpose.

Thanks,
AjeshEMC

We have a release in next 1 month and it would be really good for us if we can provide fix for this JAVA one in next 2-3 weeks.


Thanks,
AjeshEMC

The issues you have found earlier (filed as NETWRKJAVA-33410) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.

Hi Kashif Iqbal,


We are still seeing the same excpetion with aspose-email-4.6.0.0-jdk16.jar from latest link that you have provided. Please find the attached emails i have used and exception:

com.aspose.email.system.exceptions.NullReferenceException: Object reference not set to an instance of an object.
at com.aspose.email.internal.b.ap.b(Unknown Source)
at com.aspose.email.qp.b(Unknown Source)
at com.aspose.email.qp.a(Unknown Source)
at com.aspose.email.qp.interpret(Unknown Source)
at com.aspose.email.MailMessage.b(Unknown Source)
at com.aspose.email.MailMessage.load(Unknown Source)
at com.documentum.mailapp.aspose.email.impl.MailAppAsposeApis.getMailMessageFromFile(MailAppAsposeApis.java:31)
at com.documentum.mailapp.operations.inbound.DfSeparateAttachments.extractAttachments(DfSeparateAttachments.java:49)
at com.documentum.mailapp.operations.inbound.DfSeparateAttachments.execute(DfSeparateAttachments.java:29)


Code Used is here:

public MailMessage getMailMessageFromFile(String inputFile) {
MailMessage message;
MailMessageLoadOptions options = new MailMessageLoadOptions();
options.setMessageFormat(MessageFormat.getMsg());
options.setFileCompatibilityMode(FileCompatibilityMode.SkipValidityChecking);
message = MailMessage.load(inputFile, options);
return message;
}

Please find emails in the attachment. Or do we need to have any other security settings to make them work.

Thanks,
AjeshEMC

Hi Ajesh,

Could you please make sure that you are using the latest build of Aspose.Email for Java 4.6.0? I have tested this scenario at my end with this latest version and both the files are loaded fine without any exception. Please verify it at your end and let us know your feedback then.