• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Change XMP Metadata on activeDocument

New Here ,
Mar 10, 2020 Mar 10, 2020

Copy link to clipboard

Copied

Hi There,

 

I'm writing a script to export e file to different formats at once.

Before exporting i would like to set the Metadata DC.Description and DC.rights to predefined variables.

 

My code so far for changing the data is:

//XMP scripting API für die Metadaten importieren
// load the library
if (ExternalObject.AdobeXMPScript == undefined) {
    ExternalObject.AdobeXMPScript = new 
    ExternalObject("lib:AdobeXMPScript");
    };

//TheCaption = Window.prompt ("Enter a caption for the photos.");


xmp = new XMPMeta(); // object initialized with xmp packet as string
xmp.setProperty(XMPConst.NS_DC, "description", "Falafel description");
xmp.setProperty(XMPConst.NS_DC, "rights", "Falafel Copyright-HInweis");
xmpStr = xmp.serialize();

 

but how do i write this back into my app.activeDocument?

 

Thank you very much,

Jens

Views

708

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Community Expert ,
Mar 11, 2020 Mar 11, 2020

Copy link to clipboard

Copied

LATEST

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines