Link to home
Start Free TrialLog in
Avatar of JSMcCloud
JSMcCloud

asked on

Animating Text Property Values

I'm am developing a card game in which two cards battle each other and code the hit points agaisnt each other at the same time.

Even though the numbers are different, when they are finishing counting up to their maxium hit point against each other, I would like them to finish counting at the same time.

I'm using two text block controls, one for each card.  I had tried using DoubleAnimation to animate the value's text property, but it tells me that it's not of the right time, so I used DispatchTimer instead, but would like the option to use the story board as I can set their duration to be the same.

How can I fix this?
ASKER CERTIFIED SOLUTION
Avatar of adler77
adler77
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of JSMcCloud
JSMcCloud

ASKER

I code in VB so the C# code is a little hard for me to read, but even so, I understand what I need to do.  Basically, if I create a Dependency Property in my UserControl, it can then be animated and I can pass the value to the TextBlock's text property!  Makes since.  Thanks!!!!