ImageCell does not load image from URI - Android #5172
Comments
@PureWeen Are you looking at this one? |
This seems to be a perennial issue. See a very straightforward sample below. The binding is to a See also #4584 <ListView ItemsSource="{Binding Sermons}"
RefreshCommand="{Binding RefreshCommand}"
IsRefreshing="{Binding LoadingInProgress, Mode=OneWay}"
IsPullToRefreshEnabled="true"
ItemSelected="Handle_ItemSelected">
<ListView.ItemTemplate>
<DataTemplate>
<ImageCell Text="{Binding FullTitle}"
Detail="{Binding Speaker.DisplayName}"
ImageSource="{Binding Speaker.RoundedThumbnailImageUrl}" />
</DataTemplate>
</ListView.ItemTemplate>
</ListView> |
@ianthetechie Can you please open a new issue and attach a small reproduction project? Thanks! |
@ianthetechie a lot of this was rewritten for 4.0 as well so if you could test with 4.0 pre9 as well please. |
This still happening in Visual Studio for Mac Community Edition. Here is my small example: <ListView.ItemTemplate>
<DataTemplate>
<ImageCell Text="{Binding Name}"
Detail="{Binding Status}"
ImageSource="{Binding ImageUrl}"/>
</DataTemplate>
</ListView.ItemTemplate>
</ListView> And listView.ItemsSource = new List<Contact> {
new Contact {Name="Name 1", ImageUrl="http://lorempixel.com/100/100/people/1" },
new Contact {Name="Name 2", ImageUrl="http://lorempixel.com/100/100/people/2" , Status="Hey Let's talk"},
}; |
This code is kind of similar but it works. <?xml version="1.0" encoding="UTF-8"?>
<ContentPage
Padding="0, 20, 0, 0"
xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="Helloworld.ListPage2">
<ListView x:Name="listView">
<ListView.ItemTemplate>
<DataTemplate>
<ViewCell>
<StackLayout Orientation="Horizontal">
<Image Source="{Binding ImageUrl}"/>
<StackLayout>
<Label Text="{Binding Name}"/>
<Label Text="{Binding Status}" TextColor="Gray"/>
</StackLayout>
<Button Text="Follow" />
</StackLayout>
</ViewCell>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
</ContentPage> namespace Helloworld
{
public partial class ListPage2 : ContentPage
{
public ListPage2()
{
InitializeComponent();
listView.ItemsSource = new List<Contact> {
new Contact {Name="Name 1", ImageUrl="http://lorempixel.com/100/100/people/1" },
new Contact {Name="Name 2", ImageUrl="http://lorempixel.com/100/100/people/2" , Status="Hey Let's talk"},
};
}
}
} |
I have this issue in 4.2
And in Page.OnAppearing
I get the following error in my Output window
My Android HttpClient is set to Managed, and SSL/TLS is set to Native TLS 1.2+ |
We're investigating that on #7248. @MaxxDelusional We don't monitor old closed issues, so you should create new issues as you encounter problems. Thanks! |
Image are not loading from url in xamarin forms please help me |
@PraveenPotla can you create a new issue with a repro please? |
Check the emulator wifi is working !! |
Description
ImageCell not load image from URI on Android.
Steps to Reproduce
Obs.: I tested with other code, none worked.
Expected Behavior
Image showing.
Actual Behavior
Image not showing.
Exceptions: Image Loading: Error getting stream for {url image}....
Exceptions: ImageLoaderSourceHandler: Could not retrieve image or image data was invalid. {In ListView ImageCell with Binding}
Basic Information
Reproduction
The text was updated successfully, but these errors were encountered: