2

When I run animation in wpf using storyboard I am getting following error in output window.

System.Windows.Media.Animation Warning: 6 : Unable to perform action because the specified Storyboard was never applied to this object for interactive control.; Action='Stop'; Storyboard='System.Windows.Media.Animation.Storyboard'; Storyboard.HashCode='57850459'; Storyboard.Type='System.Windows.Media.Animation.Storyboard'; TargetElement='System.Windows.Media.Animation.Storyboard'; TargetElement.HashCode='57850459'; TargetElement.Type='System.Windows.Media.Animation.Storyboard'

Can anyone tell me how it will affect my program and how to remove it?

I haven't define storyboard in .xaml file. But when code behind design file(.xaml) I have created private stoaryboard in class and i am assigning it to framework element using following syntax in code.

this.storyboard1.Begin(this.viewbox1, true);

where storyboard1 is object that I have created in class and viewbox1 is element to which I want to apply this animation.

Can anybody help me? Thanks in advance.

Soner Gönül
  • 97,193
  • 102
  • 206
  • 364
Darshan
  • 151
  • 5
  • 13
  • See this [link](http://stackoverflow.com/questions/12981771/wpf-animation-warning-6-unable-to-perform-action), may be help. – Anatoliy Nikolaev Sep 16 '13 at 12:03
  • Thanks.. But I have already seen this but in that case HasCode for storyboard and target Element is different. Here it is same. I think it is problem with iscontrolled parameter of begin method. But I have set it to true. – Darshan Sep 16 '13 at 12:09

1 Answers1

2

I too had this warning, but found that the 'containingElement' specified in the Begin call must also be specified in the Stop call, which should eliminate the warning.

this.storyboard1.Begin(this.viewbox1, true);

this.storyboard1.Stop(this.viewbox1);
Gavin R
  • 21
  • 3