Open RAW file in ACR

Use this Forum for Beta-Testing your Photoshop Scripts

Moderators: xbytor, DavideBarranca, Paul MR

ucmego

Open RAW file in ACR

Postby ucmego » Mon Sep 27, 2010 9:39 am

Mike Hale wrote:No I don't think you can open even one file in ACR without the dialog. But if you skip the File.openDialog line the normal open dialog will appear that will let you select multiple files.

Code: Select allfunction OpenCameraRaw() {
  var keyNull = charIDToTypeID('null');
  var keyAs = charIDToTypeID('As  ');
  var adobeCameraRawID = stringIDToTypeID("Adobe Camera Raw");
  var desc = new ActionDescriptor();
  var overrideOpenID = stringIDToTypeID('overrideOpen');
  desc.putBoolean(overrideOpenID, true);
  var returnDesc = executeAction(charIDToTypeID('Opn '), desc, DialogModes.ALL);
  return (returnDesc.hasKey(keyAs) && returnDesc.hasKey(keyNull));
}


Hi,

Is this mean't to be a .js or .jsx file.

I'm new to this and would like to use it and understand what it can do.

BTW its great to see the forum updated haven't be to this forum for a while well done.

Cheers,

Mike Hale

Open RAW file in ACR

Postby Mike Hale » Mon Sep 27, 2010 2:32 pm

OpenCameraRaw() is a function that will allow the user to select multi camera raw files to open in ACR. It is not a standalone script. It can be added to a script when that functionally is needed.

ucmego

Open RAW file in ACR

Postby ucmego » Mon Sep 27, 2010 10:24 pm

Mike Hale wrote:OpenCameraRaw() is a function that will allow the user to select multi camera raw files to open in ACR. It is not a standalone script. It can be added to a script when that functionally is needed.

Can you confirm a couple of things:

Script doesn't work on its own.
Needs some other sdcript to call it up
Is this a .js or a .jsx script.

Thank you for your help.

Cheers,

Mike Hale

Open RAW file in ACR

Postby Mike Hale » Mon Sep 27, 2010 11:04 pm

No it is not standalone. Yes, the function needs to be called in a script before it will do anything. It is written in ExtendScript(javascript) so you can save it as either .js or .jsx.

Below is the simplest script that uses the function.

Code: Select allOpenCameraRaw();
function OpenCameraRaw() {
  var keyNull = charIDToTypeID('null');
  var keyAs = charIDToTypeID('As  ');
  var adobeCameraRawID = stringIDToTypeID("Adobe Camera Raw");
  var desc = new ActionDescriptor();
  var overrideOpenID = stringIDToTypeID('overrideOpen');
  desc.putBoolean(overrideOpenID, true);
  var returnDesc = executeAction(charIDToTypeID('Opn '), desc, DialogModes.ALL);
  return (returnDesc.hasKey(keyAs) && returnDesc.hasKey(keyNull));
};


Return to “Photoshop Scripts: Beta Testing”

Who is online

Users browsing this forum: No registered users and 1 guest