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

Unable to load the AdobeXMPScript library in Indesign CC 2021

Community Expert ,
May 06, 2021 May 06, 2021

Copy link to clipboard

Copied

Hi everyone,

I am trying to execute the following method to load AdobeXMPScript library. This perfectly works in Indeisgn CC 2020 and console 'success' which is expected behaviour but unfortunately in Indesign CC 2021, it gives an alert 'Unable to load the AdobeXMPScript library'

 

function loadXMPLibrary() {
    if (!ExternalObject.AdobeXMPScript) {
        try { ExternalObject.AdobeXMPScript = new ExternalObject('lib:AdobeXMPScript'); }
        catch (e) { alert('Unable to load the AdobeXMPScript library!'); return false; }
    }
    return true;
}

var myFile = app.activeDocument.fullName;

// check library and file
if (loadXMPLibrary() && myFile !== null) {
    xmpFile = new XMPFile(myFile.fsName, XMPConst.FILE_INDESIGN, XMPConst.OPEN_FOR_UPDATE);
    var myXmp = xmpFile.getXMP();
}

if (myXmp) {
    $.writeln('success')
}

 

What are the reasons behind it?

Is there any change to load these libray in latest version?

OS Version : MacOS BigSur

 

 

 

Best regards
TOPICS
Bug , Scripting

Views

2.6K

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

correct answers 1 Correct answer

Community Expert , May 07, 2021 May 07, 2021

Ok. Now I had the chance to run Hans-Gerd's code on InDesign 16.1.0.20.

This is working as expected.

 

It's not working with 16.2.1.100 installed from the Prerelease tab.

Hm. Don't know if the up-coming version of 16.2 that is currently rolled out in phases will react the same way.

Best I'll do a bug report at InDesign Prerelease.*

 

All done on Windows 10 Pro version 2004.

 

Regards,
Uwe Laubender

( ACP )

 

EDITED

 

* Now I know, that the rolled out version 16.2.1.102 has the same problem.

But t

...

Votes

Translate

Translate
Community Expert ,
May 06, 2021 May 06, 2021

Copy link to clipboard

Copied

Hi Charu,

I see the same with Hans-Gerd Claßen's restored code from 2014 here:

https://community.adobe.com/t5/indesign/adding-name-of-indesign-document-to-metadata-of-all-images-u...

 

With InDesign 2020 there is no issue. All is working very well.

However it fails with the current InDesign version 16.2.1.100 on my Windows 10 machine.

 

Thanks for reporting this serious issue!

 

Regards,
Uwe Laubender

( ACP )

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
Guru ,
May 06, 2021 May 06, 2021

Copy link to clipboard

Copied

Hi Uwe,

I just tested the script you mentioned in your post and it does work for me without any problems in InDesigm 16.1 x64 (Windows 10).

Unlike the active doc, links can be 'opened for update'.

2021-05-07_00-35-21.png

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
Community Expert ,
May 06, 2021 May 06, 2021

Copy link to clipboard

Copied

Thank you @Laubender  for confirming it is a bug.

I think, it started happening with 16.2 as @Kasyan Servetsky  says it works fine with 16.1

Can we forward this bug to the relevant team so that it will be fixed as soon as possible?

 

Best regards

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
Community Expert ,
May 07, 2021 May 07, 2021

Copy link to clipboard

Copied

Hi Charu,

is your 16.2. version 16.2.1.100 ?

And if so, was it installed from the Prerelease tab in your Creative Cloud Desktop App?

 

FWIW: If I run your code from the ESTK I can see the error message Kasyan also had.

I'm on Windows 10 Pro version 2004.

 

Regards,
Uwe Laubender

( ACP )

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
Community Expert ,
May 07, 2021 May 07, 2021

Copy link to clipboard

Copied

Hello Uwe,

My version is 16.2.1.102 and it is not downloaded from prerelease tab. I have updated normally yesterday from the app section of the Creative Cloud

 

FWIW: If I run your code from the ESTK I can see the error message Kasyan also had.

I'm on Windows 10 Pro version 2004.

Yes, I also tested and got the same error message as Kasyan mentioned on Windows for Indesign 2020 but it works fine on mac for Indesign 2020.

 

Best regards

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
Guru ,
May 06, 2021 May 06, 2021

Copy link to clipboard

Copied

Your code ain't working for me both in 2020 and 2021 (on Windows 10).

The library is loaded, but the file fails to open for update throwing an error: "XMP Exception: Open, other failure".

If I change UPDATE to READ, it works.

function loadXMPLibrary() {
    if (!ExternalObject.AdobeXMPScript) {
        try { ExternalObject.AdobeXMPScript = new ExternalObject('lib:AdobeXMPScript'); }
        catch (e) { alert('Unable to load the AdobeXMPScript library!'); return false; }
    }
    return true;
}

var myFile = app.activeDocument.fullName;

// check library and file
if (loadXMPLibrary() && myFile !== null) {
    var xmpFile = new XMPFile(myFile.fsName, XMPConst.FILE_INDESIGN, XMPConst.OPEN_FOR_READ);
    var myXmp = xmpFile.getXMP();
	var xmpStr = myXmp.serialize();
	$.writeln(xmpStr);
}

if (myXmp) {
    $.writeln('success');
}

 

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
Community Expert ,
May 06, 2021 May 06, 2021

Copy link to clipboard

Copied

@Kasyan Servetsky 

I just cross checked and it's true when UPDATE is used it gives an error on Windows but on Mac for 2020.

Thank you for this information.

 

Best regards

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
Community Expert ,
May 07, 2021 May 07, 2021

Copy link to clipboard

Copied

Ok. Now I had the chance to run Hans-Gerd's code on InDesign 16.1.0.20.

This is working as expected.

 

It's not working with 16.2.1.100 installed from the Prerelease tab.

Hm. Don't know if the up-coming version of 16.2 that is currently rolled out in phases will react the same way.

Best I'll do a bug report at InDesign Prerelease.*

 

All done on Windows 10 Pro version 2004.

 

Regards,
Uwe Laubender

( ACP )

 

EDITED

 

* Now I know, that the rolled out version 16.2.1.102 has the same problem.

But there is hope at the horizon. A bug fix is under way.

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
Community Expert ,
May 07, 2021 May 07, 2021

Copy link to clipboard

Copied

Thank you. 🙂

 

Best regards

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
Adobe Employee ,
May 28, 2021 May 28, 2021

Copy link to clipboard

Copied

Hi there!


The fix is expected in 16.3.

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
New Here ,
May 30, 2021 May 30, 2021

Copy link to clipboard

Copied

Any ETA on 16.3? Not sure whether I can track upcoming releases somewhere.

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
Community Expert ,
May 28, 2021 May 28, 2021

Copy link to clipboard

Copied

Erin said: "The fix is expected in 16.3."

Yep. Already tested successfully the fix with that version at Prerelease.

 

Regards,
Uwe Laubender

( ACP )

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
Contributor ,
Jul 03, 2021 Jul 03, 2021

Copy link to clipboard

Copied

I have an extension for InDesign and solving this bug is crucial to run the software. And until now I didn't get the 16.3 update! Could you please tell me when the update will come?

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
Community Beginner ,
May 31, 2022 May 31, 2022

Copy link to clipboard

Copied

This bug returned on Windows. So please fix it as quickly as possible.

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
Community Expert ,
May 31, 2022 May 31, 2022

Copy link to clipboard

Copied

17.3 is on its way with a fix.

 

Regards,
Uwe Laubender
( Adobe Community Professional )

 

 

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
Community Beginner ,
May 31, 2022 May 31, 2022

Copy link to clipboard

Copied

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
Community Expert ,
Jul 05, 2021 Jul 05, 2021

Copy link to clipboard

Copied

Well, I expect 16.3 every day.

And that for some weeks now…

 

Regards,
Uwe Laubender

( ACP )

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
Community Expert ,
Jul 05, 2021 Jul 05, 2021

Copy link to clipboard

Copied

I think it has been rolled out in some of the regions of the world. I have 16.3.2 version, may be it will be released soon for all.

 

 

Best regards

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
Community Expert ,
Apr 26, 2022 Apr 26, 2022

Copy link to clipboard

Copied

Seems that this issue is back with InDesign 2022 version 17.2.0.

 

At least on Windows machines!

It still works with 17.1.0.50, but there is evidence that it fails on version 17.2.0. on Windows 10.

 

Could someone test with 17.2.1 on Windows and MacOS as well?

I still waiting for 17.2.1 here in Germany…

 

See bug report at InDesign UserVoice:

 

AdobeXMPScript v 17.2.0.20
Windows 10
Jim McKee, April 26, 2022
https://indesign.uservoice.com/forums/601180-adobe-indesign-bugs/suggestions/45080362-adobexmpscript...

 

Also this new discussion:

 

IO error creating ExternalObject('lib:AdobeXMPScript')
jimm22973083, April 25, 2022
https://community.adobe.com/t5/indesign-discussions/io-error-creating-externalobject-lib-adobexmpscr...

 

 

Regards,
Uwe Laubender

( ACP )

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
Community Expert ,
Apr 26, 2022 Apr 26, 2022

Copy link to clipboard

Copied

Hi @Laubender 

AdobeXMPScript is working on mac for Indeisgn version 17.2.1
Best regards

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
Community Expert ,
Apr 28, 2022 Apr 28, 2022

Copy link to clipboard

Copied

Now I had a chance to test the code on Windows 10 with InDesign 17.2.0 and 17.2.1.105.

Both fail.

 

ERROR: 52, I/O error
Unable to load the AdobeXMPScript library!

 

Regards,
Uwe Laubender

( ACP )

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
Community Beginner ,
Jun 01, 2022 Jun 01, 2022

Copy link to clipboard

Copied

The bug exists now on my laptop:

 

Device name LAPTOP-GO2JNFJQ
Processor AMD Ryzen 7 4800H with Radeon Graphics 2.90 GHz
Installed RAM 16.0 GB (15.4 GB usable)
Device ID 84411421-6190-4CE9-8511-6A6EC115A6F4
Product ID 00325-96700-16024-AAOEM
System type 64-bit operating system, x64-based processor
Pen and touch Touch support with 10 touch points

 

Edition Windows 11 Home
Version 21H2
Installed on ‎11/‎3/‎2021
OS build 22000.675
Experience Windows Feature Experience Pack 1000.22000.675.0

 

Adobe InDesign Version: 17.2.1.105
Defaults File Version: 1
SavedData File Version: 19
Installed Plug-ins: 244

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
Community Expert ,
Jun 01, 2022 Jun 01, 2022

Copy link to clipboard

Copied

LATEST

Hi,

let's hope that the fix for this bug is available in all regions of the world with InDesign 17.3.0 at the end of this or early next week. Currently version 17.3.0 is available for Australia, Belgium, Canada, France, Hong Kong, India, Italy, the Netherlands, Switzerland and the United Kingdom based on Adobe IDs.

https://helpx.adobe.com/indesign/kb/fixed-issues.html

 

Regards,
Uwe Laubender
( Adobe Community Professional )

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