Free Support Forum - aspose.com

Exception"Specified argument was out of the range of valid values" on loading message (Java)

Trying to do a MapiMessage.fromMailMessage on the email attached causes this exception:

class com.aspose.email.system.exceptions.ArgumentOutOfRangeException: Specified argument was out of the range of valid values. Parameter name: Not a valid Win32 FileTime. com.aspose.email.system.DateTime.toFileTimeUtc(Unknown Source) com.aspose.email.system.DateTime.toFileTime(Unknown Source) com.aspose.email.MapiProperty.a(SourceFile:1149) com.aspose.email.MapiProperty.a(SourceFile:1055) com.aspose.email.MapiPropertyContainer.a(SourceFile:780) com.aspose.email.MapiMessage.c(SourceFile:1106) com.aspose.email.MapiMessage.f(SourceFile:3870) com.aspose.email.MapiMessage.a(SourceFile:2957) com.aspose.email.MapiMessage.b(SourceFile:2626) com.aspose.email.MapiMessage.fromMailMessage(SourceFile:1552) com.aspose.email.MapiMessage.fromMailMessage(SourceFile:1499) com.stormed.processing.AbstractEmailProduct.(AbstractEmailProduct.java:46) com.stormed.processing.concretefile.ConcreteEmlFile.(ConcreteEmlFile.java:51) com.stormed.processing.concretefile.FileFactory.parseProduct(FileFactory.java:100) com.stormed.processing.ProcessingMain.processing(ProcessingMain.java:149) com.stormed.processing.ProcessingMain.(ProcessingMain.java:64) com.stormed.processing.common.ProcessingBuilder.run(ProcessingBuilder.java:49) com.stormed.common.builder.AppDirector.build(AppDirector.java:20) com.stormed.common.main.CommonMain.run(CommonMain.java:45) com.stormed.processing.ProcessingMain.main(ProcessingMain.java:223) at com.aspose.email.system.DateTime.toFileTimeUtc(Unknown Source) at com.aspose.email.system.DateTime.toFileTime(Unknown Source) at com.aspose.email.MapiProperty.a(SourceFile:1149) at com.aspose.email.MapiProperty.a(SourceFile:1055) at com.aspose.email.MapiPropertyContainer.a(SourceFile:780) at com.aspose.email.MapiMessage.c(SourceFile:1106) at com.aspose.email.MapiMessage.f(SourceFile:3870) at com.aspose.email.MapiMessage.a(SourceFile:2957) at com.aspose.email.MapiMessage.b(SourceFile:2626) at com.aspose.email.MapiMessage.fromMailMessage(SourceFile:1552) at com.aspose.email.MapiMessage.fromMailMessage(SourceFile:1499)

code:
MailMessage message = MailMessage.load(, new EmlLoadOptions());
MapiMessage mapiMessage = MapiMessage.fromMailMessage(message);

W.PC.00052064.eml.zip (1.5 KB)

@mstandfuss,

I have investigated this issue on my end have been able to observe the issue. An issue with ID EMAILJAVA-34539 has been created in our issue tracking system to further investigate and resolve the issue. This thread has been linked with the issue so that you may be notified once the issue will be fixed.

Thank you appreciate the quick response.

@mstandfuss,

You are very welcome.

This shows that EMAILJAVA-34539 is now in a closed status, but I did not get any release notification. Can you please tell me which version it was included in?

@mstandfuss,

We regret to share that owing to some technical limitations,we couldn’t share notification with you. You may please try using latest Aspose.Email for Java 20.4 on your end to verify the issue and I hope it will work.

Is that the issue that contains this fix? Can you link some documentation or release notes that shows its fixed in that version? Were you able to confirm it was fixed on your end?

@mstandfuss,

It was fixed in Aspsoe.Email for Java 19.6. Please check this release notes link for your convenience.