Is there a way to set an element in XAML to be hidden? When users click a New Game button I want a set of buttons (probably in a stack panel) to animate into view letting the user choose the difficulty level. I tried setting Visibility to Collapsed, but when I use one of the built-in Win8 animations such as EntranceThemeTransition or PopIn the collapsed element doesn’t show up. Changing the opacity to 0 and then trying to animate using one of these has the same effect.
Share
The
Visibilityproperty works independently from Opacity. You need to setVisibilityback toVisiblebefore running a customOpacityanimation or the built inFadeInThemeAnimation.You can use the WinRT XAML Toolkit extensions to run a simple animation like this:
The extension methods class from the XAML Toolkit: