Hi everyone. I want to change some clips' end time in my timeline via scripting.
This is my code:
var proj = app.project; var srcSeq = proj.activeSequence; var time = new Time(); time.seconds = 10; var vClip = srcSeq.videoTracks.clips; var aClip = srcSeq.audioTracks.clips; vClip.end = time; aClip.end = time;
The problem is when I execute my code, it always gives me error saying that 'cannot set property end'(last two lines giving the error).
However, it actually does change my clip end time.
This happens when I set the inPoint/outPoint/start/end time on my track clip.
Am I doing somthing wrong? Or it's a bug?
Hope I can get some help.
BTW, I am on Windows 10, Premiere Pro 14.6.0(should be the latest at the current time). And I script in vscode with ExtendScript Debugger extension.
Copy link to clipboard
The error you're seeing, is the bug. 🙂
We're tracking the issue as DVAPR-4224243.
Great thanks, Bruce! And another small issue of NewWorld scripting is that it complains every time the value passed into 'Alert()' is not a string. Can we have how it behaves like in the OldWorld scripting(not complaining when getting a non-string value) in the future?
No, because implicit type conversion to string went away, with the move to New World. It's unlikely to make a return.
Thanks! And another question: Are some api methods NewWorld Scripting only? This method
Yes, this one is New World only.
It's unlikely that we'll add any new APIs to Old World; I'd also anticipate very few additions to the ExtendScript API, between now and when UXP support becomes available (no dates available).
Thanks, Bruce! Super helpful. Looking forward to UXP stuff.
Any Update/Workaround for DVAPR-4224243?