FORUMS: list search recent posts

Can I stop AE from throwing an error?

COW Forums : Adobe After Effects Expressions

Respond to this post   •   Return to posts index   •   Read entire thread

Andrei Popa
Can I stop AE from throwing an error?
on Feb 18, 2020 at 10:36:53 am

Hi guys. I am trying to serialize some variable using this json2 library.

The problem is, when trying to check property["maxValue"] for position, AE throws an error: "Property has no maximum value.". This breaks my code. If I check the model viewer, maxValue is null. If i check the console while the error is thrown, the result is null. If i try it in the console while the error is not thrown, it throws the error.

Is there any chance i can stop AE from throwing this error? I tried putting the value attribution inside a try catch statement but it still throws the error while in the JSON2 library.
Works if the only code in my script is the try catch phrase.
But if i try it inside the JSON2 library, it throws an error just before try. I don't know why and ran out of ideas to test.
The error appears at rows 244(var value = holder[key];) for values holder = scale, key = "maxValue".
I replaced that row with this and still got the error before the try/catch phrase:

var value;
value = holder[key];
}catch (e){
value = null;

Any help or hint is greatly appreciated.

My Envato portfolio.

Posts IndexRead Thread 

Current Message Thread:

© 2020 All Rights Reserved