© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•3y ago•
1 reply
aspes

add image programmatically

my images are not showing up when adding them as followed:

            Image image = new Image();
            BitmapImage bitmap = new BitmapImage(new Uri(imagePath, UriKind.Relative));
            image.Source = bitmap;
            overlayWindow.Children.Add(image);
            Image image = new Image();
            BitmapImage bitmap = new BitmapImage(new Uri(imagePath, UriKind.Relative));
            image.Source = bitmap;
            overlayWindow.Children.Add(image);


am i missing something completely? the path is correct !
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

❔ How to modify aspnetcorehealthcheck to add devices programmatically.
C#CC# / help
3y ago
ImageSharp add circular border around image
C#CC# / help
2y ago
Add console application to (see image)
C#CC# / help
3y ago