8 Replies Latest reply on Aug 1, 2016 2:50 PM by JJMack

    How can I get a delay value of animation timeline?

    maryan_coder
      function getDelay (theFrameIndex) 
      {
        try
        {
        var actionReference = new ActionReference(); 
        actionReference.putProperty(charIDToTypeID('Prpr'), stringIDToTypeID('animationFrameDelay')); 
        actionReference.putIndex(stringIDToTypeID('animationFrameClass'), theFrameIndex);
        var actionDescriptor = new ActionDescriptor(); 
        actionDescriptor.putReference(charIDToTypeID('null'), actionReference);          
        var T = executeAction(charIDToTypeID('getd'), actionDescriptor, DialogModes.NO);
        return T.getDouble(stringIDToTypeID('animationFrameDelay'))
        }
        catch(ex)
        {
        alert(ex);
        return null;
        }
      }
      

      I want to get the value of the stringIDToTypeID ( 'animationFrameDelay'). But the code falls with an error.