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

Bridge Talk from Adobe Bridge to AME

Contributor ,
Apr 26, 2023 Apr 26, 2023

I want to execute the following code in AME but from Adobe Bridge startup script. How to do that and what is the appName in BridgeTalk.getSpecifier ("appName");

And how to make a function and use talkAME.body = funObj.ToString (); and pass the parameters?

 

 

var preset = "C:\\full\\path\\to\\HighQuality720HD.epr";
var destination = "C:\\full\\path\\to\\Output";
var compItem = "C:\\full\\path\\to\\Two comps.aep";

var frontend = app.getFrontend();
if (frontend) {
  // listen for batch item added event
  frontend.addEventListener("onItemAddedToBatch", function (eventObj) {
    $.writeln("frontend.onItemAddedToBatch: success");
  });

  var batchItemSuccess = frontend.addCompToBatch(compItem, preset, destination);
  if (batchItemSuccess) {
    $.writeln(
      "Frontend script engine added the source file ",
      compItem,
      " successfully "
    );

    // get encoderHost to be able to listen for the item complete event
    encoderHost = app.getEncoderHost();
    if (encoderHost) {
      encoderHost.addEventListener("onItemEncodeComplete", function (eventObj) {
        $.writeln("Result: " + eventObj.result);
        $.writeln("Source File Path: " + eventObj.sourceFilePath);
        $.writeln("Output File Path: " + eventObj.outputFilePath);
      });

      encoderHost.runBatch();
    } else {
      $.writeln("encoderHost not valid");
    }
  } else {
    $.writeln("batch item wasn't added successfully");
  }
} else {
  $.writeln("frontend not valid");
}

 

 
TOPICS
How to , Scripting
387
Translate
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 22, 2023 May 22, 2023
Here's an example of running a code snippet in AME from another app:
 
var bt = new BridgeTalk();
bt.target = "ame";
bt.body = "alert('hello world')";
bt.send();
Translate
Community Expert ,
May 22, 2023 May 22, 2023
LATEST
Here's an example of running a code snippet in AME from another app:
 
var bt = new BridgeTalk();
bt.target = "ame";
bt.body = "alert('hello world')";
bt.send();
Translate
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