Hiding objects with effects - syntax

In my javascript code I want to hide an object from my project and I cannot find an example of the syntax in the brackets anywhere.
Page 213 of the Manual gives some info but all the different versions that I tried to hide the object did not work.
prez.object(objname1).hide(AP.EffectType.FADE_OUT, 2000);

The script works with hide(), but I do not know what the syntax should be for the first line and I cannot find any examples of the syntax. I’d really appreciate some help.

Sorry for posting such a basic question.

ActivePresenter Version: 7.5.10

OS: Win 10


Hi Rolf,

This syntax is correct. For example, to fade out Shape_1 for 2s:

prez.object("Shape_1").hide(AP.EffectType.FADE_OUT, 2000);

I guess your object is on the last slide, and your presentation already ended, so any animation with a duration other than 0 will not work anymore. If so, please extend the last slide duration, or clear its Auto Advance property. However, if you use the latter method and LMS, you should also add a button with End Presentation action and require your users to click on that button to complete the presentation.


THANKS Toanis, works perfectly now!!!

Best, Rolf