views:

40

answers:

2

How can I add an image to my program in XAML?

I want to display the 'no.png' image on my application. Also,

alt text

I need both yes and no to appear in the same place. My plan was to set them both to hidden and display them only when necessary. How can I do this?

A: 

Hi Sergio,

You could place the two png's in a StackPanel and programatically control their Visibility setting.

Mick N
+1  A: 

Hi there, yep just add the image xaml, and either use visual state manager, behaviours or code behind to switch the visibility

    <Image Source="/Background.png" Visibility="Collapsed"/>
    <Image Source="/Background.png" Visibility="Visible"/>
felixthehat