Linked Questions

4 votes
2 answers
11k views

In my assembly project I have a .png image which it's Build Action is set to Resource. Now I want to make the following: _myIcon = new BitmapImage(new Uri(**path to the image embedded on the ...
André Santaló's user avatar
1 vote
1 answer
3k views

I have added an image(image1) in my Xaml Editor, changed the source property to Source="/WpfApplication9;component/Images/a.png" I have a button, I want is, if I Clicked that button I want my image1 ...
Lemich Pablo's user avatar
-1 votes
1 answer
3k views

I am trying to set an image source in WPF but relative Uri doesn't work. imgView.Source = new BitmapImage(new Uri("Res/Images/img.png", UriKind.Relative)); But this works: imgView.Source = new ...
Uknowledge_1's user avatar
0 votes
1 answer
2k views

I want to use a background image for a window in WPF. I am intending to use ImageBrush. I have the image in the root folder and also in the Assets folder. I found many answers in StackOverflow to ...
FLash's user avatar
  • 804
1 vote
1 answer
765 views

I'm trying to change the image in a WPF application in C# when I click on a button. The image is like the background of the button, but I can't figure out how to change the image. Could someone give ...
Radek_Dom's user avatar
0 votes
0 answers
837 views

I am new to WPF and am confused as to how to load an image dynamically from a folder in the project rather than from OpenFileDialog. I have a regular grid view in XAML where I've declared an image <...
ConfusedRedPanda's user avatar
0 votes
1 answer
646 views

I am working on WPF for interactive applications. When I assign image path to ImageBrush (Canvas) from folder included in solution, its not working, it goes to bin/debug/.. in WPF. But it worked ...
Lalit choudhary's user avatar
0 votes
1 answer
548 views

I tried to get it done by doing this <Button> <StackPanel> <Image Source="Pictures/img.jpg" /> <TextBlock>Blablabla</TextBlock> </...
NataliaSmolina's user avatar
0 votes
0 answers
425 views

I want to animate the Source property of an image in WPF using a ObjectAnimationUsingKeyFrames. My images "0.png" and "1.png" are in a folder called "Assets". Both have &...
Otto's user avatar
  • 39
0 votes
2 answers
481 views

I wish I could change the path of the source image, to match the folder of my project. Current code img1.Source = new BitmapImage(new Uri("C:/Users/User/Documents/Visual Studio 2015/Projects/...
Manudog's user avatar
  • 131
0 votes
0 answers
387 views

void VideoCaptureDevice_NewFrame(object sender, NewFrameEventArgs eventArgs) { pictureBox1.Source = (Bitmap)eventArgs.Frame.Clone(); } on Windows Form this works ...
Cedric R's user avatar
3 votes
0 answers
290 views

I have found some code online that I can use on my own project. It's fairly simple, but when I run the program, I get an error message that it can not find the resource. I have tried a lot and simply ...
Kevin's user avatar
  • 151
0 votes
1 answer
894 views

I am a first year computer science student and I am having a really hard time with C#. I have been given a task where I have to create a wpf, where images have to appear and when my mouse lands on ...
Chey's user avatar
  • 1
1 vote
0 answers
184 views

I am making an application where users can make an account and add a profile image. In my Main_Page I have an Image in the Main_Page.xaml.cs I am setting Image.Source = image. image is a BitmapImage. ...
Alvaromon's user avatar
  • 220
0 votes
0 answers
178 views

I try to load a png file depending on a message type form code behind, but without success. In XAML it works if I define the image source as follows: <Image Name="MessageTypeImage" DockPanel.Dock="...
ThommyB's user avatar
  • 1,604

15 30 50 per page