Extending Dynamic Media Selection Attributes

Summary: This article explains how to define advanced Dynamic Media Selection attributes, in addition to the default color, weight and paper type attributes. For information on how to define these default attributes, see Using Dynamic Media Selection for Printing.

Overview

XMPie enables two primary types of Dynamic Media Selection:

  1. You can set a specific media type to a particular page in the InDesign template. That page will then use that paper type for each recipient. For example, page 1 will be plain paper; page 2 will be gloss paper; and this will apply to all recipients in the database. In this document, we’ll refer to this as static media selection.

  2. You can also use business rules in an ADOR object to dynamically change the paper type for a particular page based on a value in the database. For example: page 1 for recipient 1 might be plain paper; but, for recipient 2, page 1 might be gloss paper. In this document, we’ll refer to this as dynamic media selection.

You can extend the default attribute options and add more attributes such as binding type, orientation and content object name.

How to extend the Dynamic Media Selection attributes

Extending the default attributes can be done by creating an XML file named MediaTypeAttributes.xml and placing it in Adobe InDesign Installed Folder\Plug-Ins\XMPie

For example C:\Program Files\Adobe\Adobe InDesign 2025\Plug-Ins\XMPie.

To this file you can add any attribute that you like.

Note that this is done on the XMPie desktop solution, and there is no need to take any action on server side.

 

Example of the content of the MediaTypeAttributes.xml file:

<?xml version="1.0" encoding="UTF-8"?>

<MEDIA_ATTRIBUTES>

<ATTRIBUTE AttributeName="FirstName" AttributeDisplayName="First Name:" />

<ATTRIBUTE AttributeName="ProductType" AttributeDisplayName="Product Type:" />

<ATTRIBUTE AttributeName="MediaTypeDetails" AttributeDisplayName="Media Type:" />

<ATTRIBUTE AttributeName="MediaColorDetails" AttributeDisplayName="Media Color:" />

<ATTRIBUTE AttributeName="MediaQuality" AttributeDisplayName="Media Quality:" />

<ATTRIBUTE AttributeName="Coating" AttributeDisplayName="Media Coating:" />

<ATTRIBUTE AttributeName="Weight" AttributeDisplayName="Weight:" />

<ATTRIBUTE AttributeName="FoldCatalog" AttributeDisplayName="Fold Catalog:" />

<ATTRIBUTE AttributeName="Orientation" AttributeDisplayName="Fold Orientation:" />

<ATTRIBUTE AttributeName="BindingSide" AttributeDisplayName="Binding Side:" />

<ATTRIBUTE AttributeName="BindingType" AttributeDisplayName="Binding Type:" />

<ATTRIBUTE AttributeName="StitchNumber" AttributeDisplayName="Stitch Number:" />

</MEDIA_ATTRIBUTES>

 

After adding this example file, these attributes will be represented in the Page/Spread Media Selection dialog as follows:

These attributes are added to the DPART of the PDF, per page and not per recipient. This means it is a sub DPART.

The following is an example showing the "FirstName" attribute in the DPART:

 

Created by Mohammad Mansour, December 2024