Reputation: 8281
I am having a list with an Image and some labels in each view cell. I am using the binding property to populate data inside listview, So getting image URL from my model class and loading images from it. But sometimes the URL is not found and failed to load image. In that time I need to show a placeholder on that failed image instead of blank space.
<controls:CircleImage Source="{Binding imageUrl}" x:Name="patImage" WidthRequest="60" HeightRequest="60" Aspect="AspectFill" VerticalOptions="Center" />
Please let me know if there is any solution for this.
Upvotes: 1
Views: 1225
Reputation: 2981
Check out FFImageLoading. It is a drop-in replacement for images that extends them quite a bit. One of those features is loading placeholders and its an overall great library if you need to work with images.
Upvotes: 3