Skip to main content
Participant
January 16, 2026
Answered

Using insertClip to add video to end at specific tick

  • January 16, 2026
  • 1 reply
  • 467 views

I have no problem with adding a video with Extendscript to start at a specific point. But I need it to end at a specific point related to another movie's end tick.

Correct answer bbb_999

Hi Bruce. Many thanks for helping. I was missing the .duration calc. Where can I find guide to all the ExtendScript actions? I am also trying to figure out how to move clips around once they are on the timeline aalready. Is that possible or can you only dtermine a specific placement by insert from bin?


Here's all available PPro ExtendScript API documentation., including the trackItem.move() function. 🙂

1 reply

Bruce Bullis
Legend
January 16, 2026

I don't see any technical reason you couldn't do that; have you encountered a problem, doing so?

Participant
January 19, 2026

Thanks for reply, but perhaps I did not explain well. When I get the end tick of clip on layer 0 and use that to insertClip on layer 1, the clip on layer 1 starts at the end of the clip on layer 0. But what I want to do is insert the clip on layer 1 to end at the same point as the clip on layer 0. This is more a "how to" question than reporting any errors. What would the code be to ensure that the clip I add to layer 1 position it to end at the same time as clip on layer 0?

Bruce Bullis
Legend
January 20, 2026

I'd imagine that the starting time of trackItem inserted onto Track 1, which ends at the same time as an existing trackItem on Track 0, 

newTrackItemStartTime = existingTrack0TrackItem.end - newTrackItem.duration;


Does that work?