© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•3y ago•
62 replies
Mek

✅ How to display an image avalonia

<Image Source="{Binding ImagePath}" />
<Image Source="{Binding ImagePath}" />
public static string? _imagePath;
public ViewModel()
{
  ImagePath = "/Assets/logo.ico";
}
public string? ImagePath
{
  get => _imagePath;
  set => this.RaiseAndSetIfChanged(ref _imagePath, value);
}
public static string? _imagePath;
public ViewModel()
{
  ImagePath = "/Assets/logo.ico";
}
public string? ImagePath
{
  get => _imagePath;
  set => this.RaiseAndSetIfChanged(ref _imagePath, value);
}
how do I get my image to display? This isn't working
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
Next page

Similar Threads

how can i dynamically change an image in Avalonia?
C#CC# / help
7mo ago
✅ Allow user to select profile image avalonia
C#CC# / help
2y ago
✅ How To Style ScrollBar Avalonia
C#CC# / help
2y ago