Browse our Products

Aspose.Email for Java 26.6 Release Notes

All Changes

KeySummaryCategory
EMAILNET-41773Support ProductIdentifier field for Contact and AppointmentEnhancement
EMAILNET-39862MapiMessageItemBase.SetProperty produces wrong property for multiple valuesBug
EMAILNET-41788Performance regression for EML files (introduced in 23.3) in FileFormatUtil.DetectFileFormatBug
EMAILNET-41772Aspose.Email recognized some regular attachments as linked resources.Bug
EMAILNET-41769iCalendar read errorBug
EMAILNET-41764VCardPhotoType.PNG does not existBug
EMAILNET-41754Error moving emails between folders using Microsoft GraphBug

New Features

Added ProductIdentifier Support for Contacts and Appointments

You can now read and write the product identifier that created a contact or appointment, making it easier to trace the source of VCard and calendar items. This enhancement adds a ProductId property across the relevant API classes and save options objects.

Public API Changes:

  • Appointment.getProductId() – Gets or sets the id of the product that created this appointment.
  • MapiCalendar.getProductId() – Gets or sets the id of the product that created this calendar.
  • MapiContact.getProductId() – Gets or sets the id of the product that created this contact.
  • ContactSaveOptions.getProductId() – Gets or sets the id of the product that created this VCard object.

Code Example:

//contact
VCardContact contact = VCardContact.load(fileName);
String prodId = contact.getExplanatoryInfo().getProdId();
ByteArrayOutputStream ms = new ByteArrayOutputStream();
contact.save(ms, ContactSaveFormat.Msg);
MapiMessage msg = MapiMessage.load(new ByteArrayInputStream(ms.toByteArray()));
MapiContact msgСontact = (MapiContact) msg.toMapiMessageItem();
Assert.assertEquals(prodId, msgСontact.getProductId());
ms = new ByteArrayOutputStream();
MapiContactSaveOptions mopt = new MapiContactSaveOptions();
mopt.setProductId("New ProductId");
msgСontact.save(ms, mopt);

//calendar
Appointment app = Appointment.load(fileName);
prodId = app.getProductId();
ms = new ByteArrayOutputStream();
app.save(ms, new AppointmentMsgSaveOptions());
msg = MapiMessage.load(new ByteArrayInputStream(ms.toByteArray()));
MapiCalendar msgCalendar = (MapiCalendar) msg.toMapiMessageItem();
Assert.assertEquals(prodId, msgCalendar.getProductId());
ms = new ByteArrayOutputStream();
MapiCalendarMsgSaveOptions calOpt = new MapiCalendarMsgSaveOptions();
calOpt.setProductIdentifier("New ProductId");
msgCalendar.save(ms, calOpt);