Sequencer Control

This section contains reference material for the Sequencer control. See the appropriate topic for syntax details.

The Sequencer control provides timing and sequencing services for action sets, scripts used to control Microsoft® ActiveX® controls or scripts on the page. The Sequencer control calls Microsoft JScript™, Microsoft Visual Basic® Scripting Edition (VBScript) or other Web scripts.

These procedures are called by the Sequencer control's At method and can be performed once, or they can be looped by the Sequencer control. The Sequencer control calls the named script with the parameter string, and the resolved parameter string is executed. Note that this means unresolved parameters don't get executed.

For optimal performance, use only one sequencer on a page with a single action set that calls a lot of actions. You can run multiple sequencers that each execute fewer action sets simultaneously, but you will get better performance with a single sequencer executing a larger number of action sets.

As the page is loaded, the sequencers used are loaded into memory. You can use the oninit event to ensure that the sequencers are fully loaded before starting their playback.

To use the sequencer object, you must first instantiate it on the HTML page, as shown in the following code.

<OBJECT ID=sequencerObj 
    STYLE=""
    CLASSID=clsid:B0A6BAE2-AAF0-11d0-A152-00A0C908DB96>
</OBJECT>

Action Set

An action set is a logical grouping of named procedures that controls the timing and behavior of objects on the page. For example:

<script language="Jscript" FOR="Seq" event="oninit">
    Seq.item("ActionSet1").at(1.000, "RotateAll()",-1, 0.050, 1);
	Seq.item("ActionSet1").Play();
</SCRIPT>

The following tables list the properties for action sets and their syntax.

Syntax

Scriptingproperty=sequencerObj("ActionSetName").PropertyName

Possible Values

sequencerObj
String identifying the Sequencer control object.
ActionSetName
String identifying the name of the action set.
PropertyName
The action set property to be read.

Action sets support following properties.
PropertyDescription
PlayState Retrieves the current playback state of the action set: 0=stopped, 1=playing, 2=paused. Read-only at run time.
Time Retrieves the elapsed time in format seconds.milliseconds (SS.MSS) since the start of action set playback, including iterations. The default setting is zero. Read-only at run time.

Scripting Methods

This topic contains a list of the Sequencer control methods and the scripting syntax for them. Note that these methods can be used only in script.

Syntax

ScriptingsequencerObj.MethodName(Parameters)

Possible Values

sequencerObj
String identifying the Sequencer control object.
MethodName
One of the Sequencer control methods in the following table.
Parameters
Valid parameters for the MethodName method. These parameters are separated by commas, as shown in the following JScript sample.
Seq.item("ActionSet1").at
(1.000, "RotateAll()", –1, 0.050, 1); Seq.item("ActionSet1").Play();
MethodDescription
At Specifies a new action in the action set.
Pause Stops action set playback at current position. Keeps time pointer and queue.
Play Starts the action set (if stopped). Resumes sequencer playback if sequencer is paused. Ignored if sequencer is playing.
Seek Changes the current playback position of the action set to a new, specified time.
Stop Stops action set playback, resets its playback position to the beginning.

Events

This topic lists the Sequencer control events.

Syntax

Scripting<SCRIPT LANGUAGE="JavaScript" FOR=sequencerObj EVENT=event ( parameters ) >
<!--script-->
</SCRIPT>

Possible Values

sequencerObj
String identifying the Sequencer control object.
event
One of the Sequencer control events in the following table.
Parameters
Valid parameters for the event.

Note that <!--script--> in the preceding syntax and in the syntax for each event is the script executed if the event occurs.
EventDescription
oninit Occurs when sequencer is first completely loaded into memory.
onpause Occurs when action set playback has been paused.
onplay Occurs when the action set has started playback. This event is only called when the action set starts playback from a stopped or paused state, not when a currently playing action set loops back to the beginning to repeat playback.
onseek Occurs after the Seek method call has been completed.
onstop Occurs when the action set playback ends or is stopped.


Top of Page Top of Page
© 2000 Microsoft and/or its suppliers. All rights reserved. Terms of Use.