Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

232
Views
ProjectItem.moveBin() not working correctly Extends Script (Adobe)

im currently developping a script with extends script which is a javascript-similar script language, that we use to automate tasks in Adobe's Softwares (here its premiere pro) Here is what my code is doing : -i import files from a folder in my computer -then i put them in a bin in my prpro project -and for each of this file i create a bin with the file and a sequence

My problem is that the last file is not move in a bin

here is my code

    root = app.project.rootItem
    newFilesPath = "C:/Path"
    newFilesBin = root.children[0]
    
    app.project.importFiles(newFilesPath, true, newFilesBin, false)
    
    app.project.save()
    
    newFilesBin = root.children[0]
    
    for(i=0; i<newFilesBin.children.numItems; i++){
        newFile = newFilesBin.children[0]
        name = newFile.name
        
        newBin = root.createBin(name)
        file.moveBin(newBin)
    }

So if i put several file in the path it doesnt move the last file instead of moving every files

Thanks for help

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

I found the solution :

i just change the parameters of my for loop

for(i=-1; i<newFilesBin.children.numItems+1; i++)

I dont exatly know why its working but it works

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!