How to make a scroll animated textHi,<br><br>I want to make a news viewer that displays the news titles in the bottom of a WPF window.<br><br>I was thinking in doing something like a textblock, animated from the right to the left but i have several problems:<br><br>- How can i know if a determined extrimity as passed over the the correspondent window extremity in order to start animating the next news title? (i have a possible solution for this, that passes thru knowing the relative point of the element to its parent, but that leads me to the next problem)<br><br>- How can i constantly test if a determined condition is valid on an object that is running on a animation?<br><br>Well, is there any other ways of doing this?? Simpler!<br><br>Thx,<br><br>Nuno<br>© 2009 Microsoft Corporation. All rights reserved.Tue, 07 Oct 2008 09:28:51 Z8330696e-7715-479e-8027-8d9925579a17http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#8330696e-7715-479e-8027-8d9925579a17http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#8330696e-7715-479e-8027-8d9925579a17sinosoidalhttp://social.msdn.microsoft.com/Profile/en-US/?user=sinosoidalHow to make a scroll animated textHi,<br><br>I want to make a news viewer that displays the news titles in the bottom of a WPF window.<br><br>I was thinking in doing something like a textblock, animated from the right to the left but i have several problems:<br><br>- How can i know if a determined extrimity as passed over the the correspondent window extremity in order to start animating the next news title? (i have a possible solution for this, that passes thru knowing the relative point of the element to its parent, but that leads me to the next problem)<br><br>- How can i constantly test if a determined condition is valid on an object that is running on a animation?<br><br>Well, is there any other ways of doing this?? Simpler!<br><br>Thx,<br><br>Nuno<br>Tue, 27 Nov 2007 18:18:15 Z2007-11-30T05:25:31Zhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#e08b453b-da40-4cb9-9a22-f16748b673b8http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#e08b453b-da40-4cb9-9a22-f16748b673b8Matt Galbraith - MSFThttp://social.msdn.microsoft.com/Profile/en-US/?user=Matt%20Galbraith%20-%20MSFTHow to make a scroll animated text<p align=left><font face=Arial size=2>Hi Nuno,</font></p> <p align=left> </p> <p align=left>I think this is relatively simple... just take a Canvas element, and animate the Canvas.Left property of your textblock of choice to go from Canvas.ActualWidth to (0 - YourTextBlock.ActualWidth).  I coded up a quick sample for you to see.  To determine when the current animation is finished, you'll want to use the DoubleAnimation.Completed event.</p> <p align=left> </p><font size=2> <p align=left></font><font color="#0000ff" size=2> <div class=codeseg> <div class=codecontent> <div class=codesniptitle><span style="width:100%">Code Block</span></div> <p align=left><font color="#0000ff" size=2>void</font><font size=2> StartAnimation(</font><font color="#0000ff" size=2>object</font><font size=2> sender, </font><font color="#2b91af" size=2>EventArgs</font><font size=2> e)</p> <p align=left>{</p> <p align=left></font><font color="#008000" size=2>// Reuse the same text block for memory purposes... </p></font><font size=2> <p align=left></font><font color="#008000" size=2>// If you want multiple headlines simultaneously, simply append them all the same string (more performant)</p></font><font size=2> <p align=left></font><font color="#0000ff" size=2>if</font><font size=2> (MrCanvas.Children.Contains(tb))</p> <p align=left>{</p> <p align=left>MrCanvas.Children.Remove(tb);</p> <p align=left>}</p> <p align=left></font><font color="#008000" size=2>// Grab a headline and add it to the canvas... </p></font><font size=2> <p align=left></font><font color="#0000ff" size=2>if</font><font size=2> (headlineIndex &gt;= headlines.Length)</p> <p align=left>{</p> <p align=left>headlineIndex = 0;</p> <p align=left>}</p> <p align=left>tb = </font><font color="#0000ff" size=2>new</font><font size=2> </font><font color="#2b91af" size=2>TextBlock</font><font size=2>();</p> <p align=left>tb.Text = headlines[headlineIndex];</p> <p align=left>headlineIndex++;</p> <p align=left>tb.FontSize = 20;</p> <p align=left>MrCanvas.Children.Add(tb);</p> <p align=left></font><font color="#008000" size=2>// Needed to determine the width of the textblock. Update layout so its ActualWidth is measured...</p></font><font size=2> <p align=left>MrCanvas.UpdateLayout();</p> <p align=left></font><font color="#008000" size=2>// Used to make all animations take the same time. Larger values of scrollfactor = slower animation. T = D / V.</p></font><font size=2> <p align=left></font><font color="#2b91af" size=2>Double</font><font size=2> timeToTake = (MrCanvas.ActualWidth + tb.ActualWidth) / scrollfactor;</p> <p align=left></font><font color="#008000" size=2>// Start the animation... </p></font><font size=2> <p align=left></font><font color="#2b91af" size=2>DoubleAnimation</font><font size=2> da = </font><font color="#0000ff" size=2>new</font><font size=2> </font><font color="#2b91af" size=2>DoubleAnimation</font><font size=2>(MrCanvas.ActualWidth, (0.0 - tb.ActualWidth), </font><font color="#0000ff" size=2>new</font><font size=2> </font><font color="#2b91af" size=2>Duration</font><font size=2>(</font><font color="#2b91af" size=2>TimeSpan</font><font size=2>.FromSeconds(timeToTake)));</p> <p align=left></font><font color="#008000" size=2>// Start the next one when this finishes... </p></font><font size=2> <p align=left>da.Completed += </font><font color="#0000ff" size=2>new</font><font size=2> </font><font color="#2b91af" size=2>EventHandler</font><font size=2>(StartAnimation);</p> <p align=left></font><font color="#008000" size=2>// And go!</p></font><font size=2> <p align=left>tb.BeginAnimation(</font><font color="#2b91af" size=2>Canvas</font><font size=2>.LeftProperty, da);</p> <p align=left>}</p></font> <p align=left> </p></div></div> <p align=left> </p></font> <p></p><font size=2> <p align=left></p></font> <p align=left>Hope this helps,</p> <p align=left>Matt</p>Wed, 28 Nov 2007 00:57:33 Z2007-11-28T00:57:33Zhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#6dc80bd1-9456-4d41-9c63-250e3376c435http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#6dc80bd1-9456-4d41-9c63-250e3376c435tasosvalhttp://social.msdn.microsoft.com/Profile/en-US/?user=tasosvalHow to make a scroll animated textYou can also try a completely xaml based solution by using the advice from <a title="http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2415957&amp;SiteID=1" href="http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2415957&amp;SiteID=1">http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2415957&amp;SiteID=1</a><br><br>check out <span id="_ctl0_MainContent_PostFlatView"><span class=inlineLink>Douglas Stockwell's second solution. I used it for a project that needed exactly what you are looking for, though my implementation was based on an items control as opposed to a textblock (so I could dynamically add or remove news). <br><br>That way you can add a trigger for the mouse over event that pauses the animation (all in xaml). <br><br>The post will probably have what you need but If you need any more help I could dig up my implementation and explain a bit more in detail<br><br>Hope this helps,<br>Tasos<br></span></span>Wed, 28 Nov 2007 03:24:49 Z2007-11-28T03:24:49Zhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#f0071212-ca57-427c-9251-a8f187d72513http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#f0071212-ca57-427c-9251-a8f187d72513sinosoidalhttp://social.msdn.microsoft.com/Profile/en-US/?user=sinosoidalHow to make a scroll animated textHi,<br><br>Your solution is simple but i don't like it for two reasons.<br><br>First is being used a canvas which unables me to set auto measures.<br><br>Second, it only starts a new item when the first is out. I want to start it right way after the current.<br><br>Any tips?<br><br>Thx,<br><br>Nuno<br>Wed, 28 Nov 2007 10:44:37 Z2007-11-28T10:44:37Zhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#8b0f1989-1c8a-4966-8685-737fe0f58e07http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#8b0f1989-1c8a-4966-8685-737fe0f58e07Matt Galbraith - MSFThttp://social.msdn.microsoft.com/Profile/en-US/?user=Matt%20Galbraith%20-%20MSFTHow to make a scroll animated text<p align=left>Hi Nuno,</p> <p align=left>Without creating a custom control to do this, using a translate transform (as shown in the other samples) in a grid causes clipping, since the the control is automatically sized to fit the container panel (Grid, whatever), so attempting to scroll a piece of text that is larger than the width of the container will result in annoying clipping.</p> <p align=left> </p> <p align=left>To work around the auto-measure issue, you will need to either simply make the canvas the child of an auto-measuring panel such as Grid, or create a custom control for your Marquee that handles getting more width on layout.</p> <p align=left> </p> <p align=left>To give the appearance of the 2nd headline starting immediately after the 1st, you could simply append all your current headlines into one string.  Or, get tricky with math and manage two queues of DoubleAnimations and TextBlocks (not recommended)</p> <p align=left> </p> <p align=left>Good luck!</p> <p align=left>Matt</p>Wed, 28 Nov 2007 18:29:42 Z2007-12-11T02:38:20Zhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#e7e6bf7d-1b1c-454b-a622-5fab2149539fhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#e7e6bf7d-1b1c-454b-a622-5fab2149539ftasosvalhttp://social.msdn.microsoft.com/Profile/en-US/?user=tasosvalHow to make a scroll animated textI dug up my implementation that had no problem with clipping... It is a style/template for an itemscontrol (so you can dynamically add/remove items) I just added two strings for reference. the second one is a whole paragraph.<br><br>The code following is a UserControl that you can place in a window to test. Customize it as you like (you will probably only need the style to make your own implementation)<br><br> <div style="text-align:left"> <div class=codeseg> <div class=codecontent> <div class=codesniptitle><span style="width:100%">Code Block</span></div> <p>&lt;UserControl<br>    xmlns=&quot;http://schemas.microsoft.com/winfx/2006/xaml/presentation&quot;<br>    xmlns:x=&quot;http://schemas.microsoft.com/winfx/2006/xaml&quot;<br>    xmlns:Converters=&quot;clr-namespace:Utils.Avalon&quot;<br>    xmlns:System=&quot;clr-namespace:System;assembly=mscorlib&quot;<br>    x:Class=&quot;Test.UserControl1&quot;<br>    x:Name=&quot;UserControl&quot;<br>    Width=&quot;640&quot; Height=&quot;480&quot;&gt;<br>    &lt;UserControl.Resources&gt;<br>    &lt;Style TargetType=&quot;{x:Type ItemsControl}&quot;&gt;<br>            &lt;Setter Property=&quot;Template&quot;&gt;<br>                &lt;Setter.Value&gt;<br>                    &lt;ControlTemplate TargetType=&quot;{x:Type ItemsControl}&quot;&gt;<br>                        &lt;ControlTemplate.Resources&gt;<br>                            &lt;Converters:SignConverter x:Key=&quot;signChanger&quot;/&gt;<br>                            &lt;Converters:JScriptConverter x:Key=&quot;JScript&quot; TrapExceptions=&quot;True&quot;/&gt;<br>                        &lt;/ControlTemplate.Resources&gt;<br><br>                        &lt;Border <br>                        Background=&quot;{TemplateBinding Background}&quot;<br>                        BorderBrush=&quot;{TemplateBinding BorderBrush}&quot;<br>                        BorderThickness=&quot;{TemplateBinding BorderThickness}&quot;<br>                        x:Name=&quot;border&quot;<br>                    &gt;<br>                            &lt;!-- Use a canvas so the child item has as much space as it wants --&gt;<br>                            &lt;Canvas ClipToBounds=&quot;True&quot; x:Name=&quot;container&quot;&gt;<br><br>                                &lt;!-- The grid that gets it's tranlatetransform animated. --&gt;<br>                                &lt;!-- Notice the height binding that is used to create enough height to fill the canvas --&gt;<br>                                &lt;Grid <br>                                Name=&quot;marquee&quot; VerticalAlignment=&quot;Center&quot;<br>                                Height=&quot;{Binding ElementName=border, Path=ActualHeight, Converter={StaticResource JScript}, ConverterParameter=values[0]}&quot;<br>                            &gt;<br>                                    &lt;Grid.RenderTransform&gt;<br>                                        &lt;TranslateTransform x:Name=&quot;translate&quot;&gt;<br>                                            &lt;TranslateTransform.X&gt;<br>                                                &lt;!-- The initial value that is bound is the width of the container plus the width of the listbox--&gt;<br>                                                &lt;MultiBinding Converter=&quot;{StaticResource JScript}&quot;<br>                              ConverterParameter=&quot;values[0] + values[1]&quot;&gt;<br>                                                    &lt;Binding ElementName=&quot;container&quot; Path=&quot;ActualWidth&quot; /&gt;<br>                                                    &lt;Binding ElementName=&quot;ItemsHolder&quot; Path=&quot;ActualWidth&quot; /&gt;<br>                                                &lt;/MultiBinding&gt;<br>                                            &lt;/TranslateTransform.X&gt;<br>                                        &lt;/TranslateTransform&gt;<br>                                    &lt;/Grid.RenderTransform&gt;<br><br>                                    &lt;!-- The listbox containing the items --&gt;<br>                                    &lt;ListBox VerticalAlignment=&quot;Center&quot;<br>                                    Background=&quot;{x:Null}&quot; BorderBrush=&quot;{x:Null}&quot; x:Name=&quot;ItemsHolder&quot;<br>                                    ItemsSource=&quot;{Binding Path=Items, RelativeSource={RelativeSource TemplatedParent}}&quot; <br>                                &gt;<br>                                        &lt;!-- This is used to make the items start from outside the screen --&gt;<br>                                        &lt;ListBox.RenderTransform&gt;<br>                                            &lt;TranslateTransform&gt;<br>                                                &lt;TranslateTransform.X&gt;<br>                                                    &lt;Binding Path=&quot;ActualWidth&quot;<br>                                                   ElementName=&quot;ItemsHolder&quot;<br>                                                   Converter=&quot;{StaticResource JScript}&quot;<br>                                                   ConverterParameter=&quot;-values[0]&quot; /&gt;<br>                                                &lt;/TranslateTransform.X&gt;<br>                                            &lt;/TranslateTransform&gt;<br>                                        &lt;/ListBox.RenderTransform&gt;<br><br>                                        &lt;!-- Make the items stack horizontally --&gt;<br>                                        &lt;ListBox.ItemsPanel&gt;<br>                                            &lt;ItemsPanelTemplate&gt;<br>                                                &lt;StackPanel Orientation=&quot;Horizontal&quot;/&gt;<br>                                            &lt;/ItemsPanelTemplate&gt;<br>                                        &lt;/ListBox.ItemsPanel&gt;<br>                                    &lt;/ListBox&gt;<br>                                &lt;/Grid&gt;<br>                            &lt;/Canvas&gt;<br>                        &lt;/Border&gt;<br><br>                        &lt;ControlTemplate.Triggers&gt;<br><br>                            &lt;!-- When the control loads start a continuous animation from the value of the TranslateTransform.X of the grid to 0 --&gt;<br>                            &lt;EventTrigger RoutedEvent=&quot;FrameworkElement.Loaded&quot;&gt;<br>                                &lt;BeginStoryboard x:Name=&quot;BeginMoving&quot;&gt;<br>                                    &lt;Storyboard RepeatBehavior=&quot;Forever&quot;&gt;<br>                                        &lt;DoubleAnimation To=&quot;0&quot;<br>                                       Storyboard.TargetName=&quot;translate&quot;<br>                                       Storyboard.TargetProperty=&quot;X&quot;<br>                                       Duration=&quot;0:0:30&quot; <br>                                    /&gt;<br>                                    &lt;/Storyboard&gt;<br>                                &lt;/BeginStoryboard&gt;<br>                            &lt;/EventTrigger&gt;<br><br>                            &lt;!-- When the mouse enters pause the animation --&gt;<br>                            &lt;EventTrigger RoutedEvent=&quot;FrameworkElement.MouseEnter&quot;&gt;<br>                                &lt;EventTrigger.Actions&gt;<br>                                    &lt;PauseStoryboard BeginStoryboardName=&quot;BeginMoving&quot;/&gt;<br>                                &lt;/EventTrigger.Actions&gt;<br>                            &lt;/EventTrigger&gt;<br><br>                            &lt;!-- When the mouse leaves resume the animation --&gt;<br>                            &lt;EventTrigger RoutedEvent=&quot;FrameworkElement.MouseLeave&quot;&gt;<br>                                &lt;EventTrigger.Actions&gt;<br>                                    &lt;ResumeStoryboard BeginStoryboardName=&quot;BeginMoving&quot;/&gt;<br>                                &lt;/EventTrigger.Actions&gt;<br>                            &lt;/EventTrigger&gt;<br><br>                        &lt;/ControlTemplate.Triggers&gt;<br>                    &lt;/ControlTemplate&gt;<br>                &lt;/Setter.Value&gt;<br>            &lt;/Setter&gt;<br>        &lt;/Style&gt;<br>        &lt;/UserControl.Resources&gt;<br>        &lt;ItemsControl&gt;<br>        &lt;System:String&gt;String 1&lt;/System:String&gt;<br>        &lt;System:String&gt;orem ipsum dolor sit amet, consectetuer adipiscing elit. Vivamus suscipit suscipit erat. Integer lacinia. Proin tristique accumsan tellus. Sed lacus arcu, feugiat sed, lobortis eget, consectetuer et, nibh. Nam ultricies, diam fermentum pharetra commodo, metus turpis consequat lorem, vel viverra tortor nisl eu leo. In turpis arcu, rhoncus id, lacinia non, imperdiet tempus, lacus. Curabitur pretium, velit vitae blandit placerat, lectus felis sagittis lectus, sit amet fermentum sapien sapien et ante. Nam viverra, elit sit amet congue aliquet, dui nisi ultricies magna, id euismod libero ante id tortor. Phasellus congue risus eu orci. Sed felis dui, dictum nec, consectetuer vel, rutrum hendrerit, quam. Suspendisse vel nisi. Donec sit amet dui. Cras faucibus, metus in molestie venenatis, odio nibh tincidunt neque, nec bibendum diam tellus ac neque.&lt;/System:String&gt;<br>        &lt;/ItemsControl&gt;<br>&lt;/UserControl&gt;<br></p></div></div><br>The sign converter just takes a number and returns its negative value. (Probably could be done with the JScript too). I also have triggers for pausing the animation on mouseover<br><br>It has worked well for me with no clipping issues. If you need any further help tell me. I hope this helps<br><br>PS. Sorry for the non-coloured code but I still haven't figured how to send code like that <img src="http://forums.microsoft.com/MSDN/WebResource.axd?d=NySzF1eivP_rMoc50GQJzcvS4MHMOEKwYrCIgDtzuzlw7GsNki3H_INlfYaLgkxFCLVvZNcnIJT9x2uZNvyuIGWah9F3g0vyQYx7NayjHus1&amp;amp;t=633263991144971555">.<br>The copy source as html plugin does not work in the xaml editor (let alone that I use a dark theme...)<br></div>Thu, 29 Nov 2007 00:46:49 Z2007-11-30T05:25:31Zhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#7c602f7a-5b38-48c3-bda1-2131789b7d5fhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#7c602f7a-5b38-48c3-bda1-2131789b7d5fsinosoidalhttp://social.msdn.microsoft.com/Profile/en-US/?user=sinosoidalHow to make a scroll animated textHi,<br><br>Matt, i discovered by myself the problem you have just decribed. I was driving nuts seeing the content cliped!! But i didnt gave up and i found that i could do what i wanted using a viewbox. I used your function but i modified it completly. Here is what i have done:<br><br> <div style="text-align:left"> <div class=codeseg> <div class=codecontent> <div class=codesniptitle><span style="width:100%">Code Block</span></div> <p>&lt;Viewbox OpacityMask=&quot;{x:Null}&quot; HorizontalAlignment=&quot;Center&quot; VerticalAlignment=&quot;Stretch&quot; Width=&quot;Auto&quot; Height=&quot;Auto&quot; RenderTransformOrigin=&quot;0.5,0.5&quot; x:Name=&quot;container&quot; Stretch=&quot;Uniform&quot; StretchDirection=&quot;Both&quot;&gt;<br>        &lt;Viewbox.RenderTransform&gt;<br>            &lt;TransformGroup&gt;<br>                &lt;ScaleTransform ScaleX=&quot;1&quot; ScaleY=&quot;1&quot;/&gt;<br>                &lt;SkewTransform AngleX=&quot;0&quot; AngleY=&quot;0&quot;/&gt;<br>                &lt;RotateTransform Angle=&quot;0&quot;/&gt;<br>                &lt;TranslateTransform X=&quot;640&quot; Y=&quot;0&quot;/&gt;<br>            &lt;/TransformGroup&gt;<br>        &lt;/Viewbox.RenderTransform&gt;<br>        &lt;TextBlock RenderTransformOrigin=&quot;0.5,0.5&quot; HorizontalAlignment=&quot;Center&quot; x:Name=&quot;tb&quot; VerticalAlignment=&quot;Center&quot; Width=&quot;Auto&quot; Height=&quot;Auto&quot; FontSize=&quot;50&quot; TextWrapping=&quot;NoWrap&quot; Background=&quot;{x:Null}&quot; Foreground=&quot;#FFFFFFFF&quot; Padding=&quot;0,0,0,10&quot; Text=&quot;0&quot;&gt;<br>            &lt;TextBlock.RenderTransform&gt;<br>                &lt;TransformGroup&gt;<br>                    &lt;ScaleTransform ScaleX=&quot;1&quot; ScaleY=&quot;1&quot;/&gt;<br>                    &lt;SkewTransform AngleX=&quot;0&quot; AngleY=&quot;0&quot;/&gt;<br>                    &lt;RotateTransform Angle=&quot;0&quot;/&gt;<br>                    &lt;TranslateTransform X=&quot;640&quot; Y=&quot;0&quot;/&gt;<br>                &lt;/TransformGroup&gt;<br>            &lt;/TextBlock.RenderTransform&gt;<br>        &lt;/TextBlock&gt;<br>    &lt;/Viewbox&gt;</p></div></div><br></div><br> <div style="text-align:left"> <div class=codeseg> <div class=codecontent> <div class=codesniptitle><span style="width:100%">Code Block</span></div> <p>private void StartAnimation(object sender, EventArgs e)<br>        {<br>            tb.Text = news;<br><br>            MainWindow.UpdateLayout();<br><br>            Double timeToTake = (MainWindow.Width + tb.ActualWidth) / scrollfactor;<br>           <br>            this.tb.RenderTransform = tt;<br>            Storyboard sb = new Storyboard();<br>            <br>            DoubleAnimation daX = new DoubleAnimation(MainWindow.Width, (0.0 - tb.ActualWidth), new Duration(TimeSpan.FromSeconds(timeToTake)));<br>            daX.RepeatBehavior = RepeatBehavior.Forever;<br>            <br>            Storyboard.SetTargetName(daX, TranslateTransformName);<br>            Storyboard.SetTargetProperty(daX, new PropertyPath(TranslateTransform.XProperty));<br>            sb.Children.Add(daX);<br>            sb.Begin(this.tb);<br>        }</p></div></div><br>What i needed was a scrool that could automaticly adapt the content size and the viewbox works perfectly.<br><br>About starting another right after the end of the current i gave up since is a good way of marking the end of the cycle.<br><br>Thxs for your help,<br><br>Nuno<br></div>Thu, 29 Nov 2007 09:32:18 Z2007-11-29T09:32:18Zhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#c699b24f-6436-4a94-a214-9fd16109f40ehttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#c699b24f-6436-4a94-a214-9fd16109f40eMarco Zhouhttp://social.msdn.microsoft.com/Profile/en-US/?user=Marco%20ZhouHow to make a scroll animated text<p align=left><font face=Verdana>I also mark tasosval's reply as an answer, because in my humble opinion, his reply is also a good solution.</font></p> <p align=left><font face=Verdana></font> </p> <p align=left><font face=Verdana>Thanks</font></p>Fri, 30 Nov 2007 05:27:33 Z2007-11-30T05:27:33Zhttp://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#8b093f77-67ce-44b8-bc81-911dfe484f34http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/8330696e-7715-479e-8027-8d9925579a17#8b093f77-67ce-44b8-bc81-911dfe484f34Xcelsiorhttp://social.msdn.microsoft.com/Profile/en-US/?user=XcelsiorHow to make a scroll animated textHow, this is great... it is exactly what I was looking for. <br><br>I wanted to do something similar but with dynamic duration... but I am kind of new to WPF and I don't know how to do that. Can you please explain me?<br><br>Thank you so much.<br><br><br>Best regards,<br><br>FB<br> Tue, 07 Oct 2008 09:28:51 Z2008-10-07T09:28:51Z