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

214
Visualizações
How do I Wait With Extends Script (Adobe)

i'm currently working on an extends script which is the technology that we can use to create extension for adobe softwares, its a javascript similar script language Im working on a script to automate some boring and repetitive tasks

Here is my problem i've to wait the creation of a bin before use a variable which call this bin but i can't, i tried

.then( Promise => { //Some Code }) ; setTimeout(Function(), time); nothing is working

Can someone help me please ? Here is my code

    root = app.project.rootItem
    newFilesPath = "Path"
    newFilesBin = root.children[0]
    
    app.project.importFiles(newFilesPath, true, newFilesBin, false)
    
    app.project.save()
    
    for(i=0; i<newFilesBin.children.numItems; i++){  //here is the problem it tells me that
        newFile = newFilesBin.children[i]            //newFilesBin is null, i think he has not the 
                                                     //time to create the file and then to put it 
                                                     //in the variable
        name = newFile.name
    
        newTiktokBin = root.createBin(name)
    
        root.children[i].children[0].moveBin(newTiktokBin)
    }

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

0

You can simply send your program to sleep for any amount of milliseconds by using the $.sleep() method.

$.sleep(1000);  // sends the program to sleep for a second

There is no such thing as .then() or promises in ExtendScript, as it is basically an ancient version of JavaScript.

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