-2

This is my first WPF Application.

I embedded 3 JPG files as resources.

I added 3 IMAGE boxes in the designer.

How do I get the image boxes to show a particular embedded JPG file?

When I was using Windows Forms, I would just add:

pictureBox5.Image = Properties.Resources.AllOff;

I don't see PictureBoxes in WPF.

ρяσѕρєя K
  • 132,198
  • 53
  • 198
  • 213
Daniel Steele
  • 33
  • 1
  • 1
  • 7
  • 1
    It's exactly like WinForms. Both allow you to add images. Both allow you to add controls to display images. Both allow you to do so from the designer and not code behind (which generally is the WPF way). Anyway, what research have you done? [ask] –  Jan 21 '17 at 13:57
  • Possible duplicate of [Setting WPF image source in code](http://stackoverflow.com/questions/350027/setting-wpf-image-source-in-code) – Dour High Arch Jan 22 '17 at 16:18

1 Answers1

0

As i'm not able to comment due to the lack of reputation, but i still want to help i have to answer.

I think it lacked a bit of research on your part. This might help you out.

I think the accepted answer is detailed enough so i just have to lead you there.

Community
  • 1
  • 1
Julian
  • 116
  • 4
  • 7
  • 1- Thank you, 2-A little background, I started Programming in c# about 2 months ago, no schooling, I just bought a C# for Dummies book. 3-Our company is switching from Windows Forms to WPF for all new software. I was getting OK with windows forms, but WPF is kicking my butt., The coding side is ok, it's working with the designer and XAML that is the cause of the confusion. 4-Yes the code link above help. – Daniel Steele Jan 22 '17 at 15:20