--- title: "How to: Control a Storyboard After It Starts" ms.date: "03/30/2017" dev_langs: - "csharp" - "vb" helpviewer_keywords: - "Storyboards [WPF], controlling after start" ms.assetid: 040f13f0-69f9-4ab5-be2b-079f4f80c7c0 --- # How to: Control a Storyboard After It Starts This example shows how to use code to control a after it has started. To control a storyboard in [!INCLUDE[TLA2#tla_xaml](../../../includes/tla2sharptla-xaml-md.md)], use and objects; for an example, see [Use Event Triggers to Control a Storyboard After It Starts](how-to-use-event-triggers-to-control-a-storyboard-after-it-starts.md). To start a storyboard, you use its method, which distributes the storyboard's animations to the properties they animate and starts the storyboard. To make a storyboard controllable, you use the method and specify **true** as the second parameter. You can then use the storyboard's interactive methods to pause, resume, seek, stop, speed up, or slow down the storyboard, or advance it to its fill period. The following is a list of the storyboard's interactive methods: - : Pauses the storyboard. - : Resumes a paused storyboard. - : Sets the storyboard's interactive speed. - : Seeks the storyboard the specified location. - : Seeks the storyboard to the specified location. Unlike the method, this operation is processed before the next tick. - : Advances the storyboard to its fill period, if it has one. - : Stops the storyboard. In the following example, several storyboard methods are used to interactively control a storyboard. > [!NOTE] > To see an example of controlling a storyboard using triggers with [!INCLUDE[TLA2#tla_xaml](../../../includes/tla2sharptla-xaml-md.md)], see [Use Event Triggers to Control a Storyboard After It Starts](how-to-use-event-triggers-to-control-a-storyboard-after-it-starts.md). ## Example [!code-csharp[timingbehaviors_procedural_snip#ControlStoryboardExampleUsingWholePage](~/samples/snippets/csharp/VS_Snippets_Wpf/timingbehaviors_procedural_snip/CSharp/ControlStoryboardExample.cs#controlstoryboardexampleusingwholepage)] [!code-vb[timingbehaviors_procedural_snip#ControlStoryboardExampleUsingWholePage](~/samples/snippets/visualbasic/VS_Snippets_Wpf/timingbehaviors_procedural_snip/visualbasic/controlstoryboardexample.vb#controlstoryboardexampleusingwholepage)] ## See also - [Use Event Triggers to Control a Storyboard After It Starts](how-to-use-event-triggers-to-control-a-storyboard-after-it-starts.md)