0

Here is my XAML datatemplate:

<DataTemplate>
    <Ellipse Height="40" Width="40">
        <Ellipse.Fill>
            <ImageBrush ImageSource="{Binding Photo}" Stretch="UniformToFill"/>
        </Ellipse.Fill>
    </Ellipse>
</DataTemplate>

And my Photo Binding using local image with IP ex : 192.168.1.1/image/image.jpg

I tried call binding Photo but in my ListView my image did not appear.

1
  • How is the Photo property declared? Where is the DataTemplate used? Is the DataContext set correctly? Are there any data bindng error messages in the Output Window in Visual Studio when you debug the application? Commented Aug 24, 2020 at 6:09

1 Answer 1

1

If you are getting image from a local website, you should include http:// in the path:

public Uri Photo { get; } = new Uri("http://192.168.1.1/image/image.jpg");
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.