Photoshop: Suppress "Can't locate link assets" dialog from Java Script

  • 1
  • Problem
  • Updated 3 weeks ago
  • (Edited)
OS: Mac OSX Yosemite 10.10.5
Photoshop Version: Photoshop CC 2015 20150529

Photoshop CC 2015 pops up dialog in case of linked asset i.e. Smart Object is not found even when we ask not to display any dialog from Java Script.

In the following script first we are suppressing any dialog from Photoshop.

JS Code:

app.displayDialogs = DialogModes.NO;
$infile = "missing link.tif"; File($infile));
But it opens a dialog saying "Can't locate link assets:" on CC 2015 and the script is blocked at open() call unless user interact and close the dialog.

When these documents are open on earlier version of Photoshop, they use to open a dialog saying:

"This document contains unknown data which will be discarded to keep layers editable. To preserve the original appearance instead, choose Flatten to load composite data as a flattened image."

But that dialog can be suppressed from Java Script:
app.displayDialogs = DialogModes.NO;

From CC 2015 the new dialog is always opening.

1. How can we suppress the new dialog which started showing from CC 2015 onward?
2. Rather than opening the link missing dialog, can you please throw an exception from open() call saying which links are broken?

Thanks in advance,
Photo of Niranjan Bai

Niranjan Bai

  • 4 Posts
  • 0 Reply Likes

Posted 3 years ago

  • 1
Photo of Eric Ching

Eric Ching, Employee

  • 87 Posts
  • 48 Reply Likes
Official Response
Hi Niranjan,

It looks like you are running Photoshop 2015.0.1 or 2015.0.  This is working in the current version of Photoshop, 2015.1.2. Could you update Photoshop and check again?