ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Invalid Object error when script tries to locate specific effect parameter

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Dirk de Jong
Invalid Object error when script tries to locate specific effect parameter
on Jan 12, 2018 at 12:16:27 am

I have a script that stops running with an Invalid Object error as it is attempting to to apply an expression to an effect parameter. I have several other instances of this sort of thing that seem to be working fine and I'm trying to figure out how to fix this one... The effect is the standard AE Exposure effect ("ADBE Exposure2") and the parameter it's trying to find is the parameter called "Exposure". The only thing I see that is at all "different" is that the parameter is within a param group (called "Master")... The default expression seems to show the index for this parameter to be (3)... I've tried it by index or by name with the same problem either way... - what am I missing here ? (any suggestions appreciated)...

The syntax in the script is like this
myEffect02.property(3).expression = 'whatever expression'
with myEffect02 as a properly defined variable referring to the instance of the Exposure effect...





Return to posts index

Dan Ebberts
Re: Invalid Object error when script tries to locate specific effect parameter
on Jan 12, 2018 at 12:26:14 am

Have you possibly added or deleted other effects after defining the variable that references the effect receiving the expression? That would probably invalidate the object reference.


Dan



Return to posts index

Dirk de Jong
Re: Invalid Object error when script tries to locate specific effect parameter
on Jan 12, 2018 at 3:23:24 am

[Dan Ebberts] "Have you possibly added or deleted other effects after defining the variable that references the effect receiving the expression?"

Yes, that was it. I (the script) had added another effect... and I wasn't even aware that would necessarily be a problem. I guess I had happened to never do it in that order before (because I had done this quite a bit and never had the problem before)... Thanks for the quick reply (and solution)


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 CreativeCOW.net All Rights Reserved
[TOP]