Tag Archives: load pictures

Load an image at runtime in WPF and C#

This example shows how to load an image at runtime in a WPF program. As is often the case with WPF, it’s easy once you know what to do. It’s figuring out what to do that’s hard. In short, you … Continue reading

Posted in graphics, image processing, wpf | Tagged , , , , , , , , , , , , , , | Leave a comment

Use a loop to load pictures in C#

When the form loads, the following code loads pictures into the form’s PictureBoxes. private void Form1_Load(object sender, EventArgs e) { string dirname = Path.GetFullPath( Path.Combine(Application.StartupPath, @”..\..\”)); // Make an array holding the PictureBoxes. PictureBox[] pics = { PictureBox1, PictureBox2, PictureBox3, … Continue reading

Posted in graphics, image processing | Tagged , , , , , , , , , | Leave a comment