Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

385
Visualizações
Alert "Completed" everytime after specific action applied in photoshop

I want to get a Javascript alert when a user in photoshop apply a action by click. check this Screenshot .Here, When user click on gray color action will be applied after that it should give a alert that completed.

i tried below this code, but its not working. Looking forward your help.

app.actions["actionName"].onComplete(function(){ alert('action name - completed') })

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

You'll want a function that will call the action. In my example, I've got an action that flattens all the layers. Just replace the name of the action and it's action set with the one you want ("Check new with trim").

// Play action
// replace these parameters with your own
play_action("Flatten layers", "My Favourite Actions");

function play_action(actName, actSet)
{
    // =======================================================
    var idPly = charIDToTypeID( "Ply " );
    var desc1784 = new ActionDescriptor();
    var idnull = charIDToTypeID( "null" );
    var ref572 = new ActionReference();
    var idActn = charIDToTypeID( "Actn" );
    ref572.putName( idActn, actName ); // Action name
    var idASet = charIDToTypeID( "ASet" );
    ref572.putName( idASet, actSet ); // Action set name
    desc1784.putReference( idnull, ref572 );
    executeAction( idPly, desc1784, DialogModes.NO );

    alert("action " + actName + " complete.")
}
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda