GroupDocs.Metadata for .NET 20.6 Release Notes

Major Features

There are the following features, enhancements and fixes in this release:

  • Implement the ability to add, update and remove IPTC metadata in TIFF images
  • Implement the ability to export metadata properties to an xls/xlsx worksheet
  • Exception: Could not read MPP format

Full List of Issues Covering all Changes in this Release

KeySummaryCategory
METADATANET-2495Implement the ability to add, update and remove IPTC metadata in TIFF imagesNew Feature
METADATANET-3332Implement the ability to export metadata properties to an xls/xlsx worksheetImprovement
METADATANET-3338Exception: Could not read MPP formatBug

Public API and Backward Incompatible Changes

Implement the ability to add, update and remove IPTC metadata in TIFF images

This new feature allows the user to add, update and remove IPTC metadata packages in TIFF images.

Public API changes

The TiffRootPackage class now implements the IIptc interface

The setter has bee added to the TiffRootPackage.IptcPackage property

Use cases

Add or update IPTC metadata in a TIFF image

using (Metadata metadata = new Metadata(@"D:\input.tif"))
{
	IIptc root = metadata.GetRootPackage() as IIptc;
	if (root != null)
	{
		// Set the IPTC package if it's missing
		if (root.IptcPackage == null)
		{
			root.IptcPackage = new IptcRecordSet();
		}
		if (root.IptcPackage.EnvelopeRecord == null)
		{
			root.IptcPackage.EnvelopeRecord = new IptcEnvelopeRecord();
		}
		root.IptcPackage.EnvelopeRecord.DateSent = DateTime.Now;
		root.IptcPackage.EnvelopeRecord.ProductID = Guid.NewGuid().ToString();

		// ...

		if (root.IptcPackage.ApplicationRecord == null)
		{
			root.IptcPackage.ApplicationRecord = new IptcApplicationRecord();
		}
		root.IptcPackage.ApplicationRecord.ByLine = "GroupDocs";
		root.IptcPackage.ApplicationRecord.Headline = "test";
		root.IptcPackage.ApplicationRecord.ByLineTitle = "code sample";
		root.IptcPackage.ApplicationRecord.ReleaseDate = DateTime.Today;

		// ...

		metadata.Save(@"d:\output.tif");
	}
} 

Implement the ability to export metadata properties to an xls/xlsx worksheet

This improvement allows the user to export an arbitrary set of metadata properties to an Excel workbook.

Public API changes

The GroupDocs.Metadata.Export namespace has been introduced

The ExportFormat enum has been added to the GroupDocs.Metadata.Export namespace

The ExportManager class has been added to the GroupDocs.Metadata.Export namespace

Use cases

Export the whole metadata tree to an Excel workbook

using (Metadata metadata = new Metadata(@"D:\input.doc"))
{
	RootMetadataPackage root = metadata.GetRootPackage();
	if (root != null)
	{
		// Initialize the export manager with the root metadata package to export the whole metadata tree
		ExportManager manager = new ExportManager(root);
		manager.Export(@"D:\export.xls", ExportFormat.Xls);
	}
}