I'm trying to display a button that displays some text. In every x seconds, the button must be slid to the left and must be reappear with a new text inside.
I can not use popup due to another object on my page.
Any ideas how to do that?
I'm already trying with a grid, except that I do not have to slide it.
XAML
& lt; Grid x: name = "PropoCloud" VerticalAlignment = "Down" & gt; & Lt; Tut: TutorialAwareButton name = "PropoButton" style = "{StaticResource tplButtonCloud}" Command = "{CmdCreated Binding}" BorderThickness = "0" VerticalAlignment = "bottom" HorizontalAlignment = "left" width = "410" height = "200" & Gt; & Lt; Tutorial: TutorialAwareButton.CommandParameter & gt; & Lt; Cmd: Navigation Common Parameter TargetName = "Question Creating View" & gt; & Lt; / Cmd: Navigation Commands Parameters & gt; & Lt; / Tutorial: TutorialAwareButton.CommandParameter & gt; & Lt; / Tutorial: TutorialAwareButton & gt; & Lt; / Grid & gt;
C #
private void SuggestionCycling () {if (PropoCloud.Visibility == Visibility.Visible) {PropoCloud. Visibility = Visibility Collapsed; } Other {PropoCloud.Visibility = Visibility Visible; }}
've posted the code will only show the back of the dark and Control you need animation to fly and bring it ... Take a look at this animation is how can ...
provided went links do not make changes to copy you, To understand your needs and to understand the concept
This is a functionnal solution:
& lt; VisualStateManager.VisualStateGroups & gt; & Lt; VisualState Group x: name = "FedStates" & gt; & Lt; VisualState X: Name = "FadeOut" & gt; & Lt; Storyboard & gt; & Lt; Double animation storyboard TITLEName = "PropoCloud" storyboard. TargetProperty = "PropoCloud.Opacity" = "1" from = "0" period = "0: 0: 1" /> & Lt; / Storyboard & gt; & Lt; / VisualState & gt; & Lt; VisualState X: Name = "Faidin" & gt; & Lt; Storyboard & gt; & Lt; DoubleAnimation Storyboard.TargetName = "PropoCloud" Storyboard.TargetProperty = "PropoCloud.Opacity" from = "0" to = "1" period = "0: 0: 2" / & gt; & Lt; / Storyboard & gt; & Lt; / VisualState & gt; & Lt; / VisualStateGroup & gt; & Lt; /VisualStateManager.VisualStateGroups>
Simply add FadeOut.Storyboard.Begin ();
and FadeIn.Storyboard.Begin ();
in your timer cycle
No comments:
Post a Comment