question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

bindable not an instance of AssociatedType for Triggers on ffimageloading:CachedImage

See original GitHub issue

Hey guys, since I am new to Xamarin, this question/issue may be more a result of my inexperience than an actual bug. I was having issues with images loading in an Android listview until I found your package, which seems to work great. I am using FFImageLoading.Forms with a Xamarin Forms project and I am trying to use image triggers to change one image to another based on a setting value. The error I get when I implement my trigger is “bindable not an instance of AssociatedType”. Below is my xaml image. Am I missing something?

<ffimageloading:CachedImage Grid.Column="3"
                                                      Grid.Row="0" 
                                                      Grid.RowSpan="2"
                                                      HorizontalOptions="End"
                                                      VerticalOptions="Center"
                                                      DownsampleHeight="25"
                                                      DownsampleWidth="25"
                                                      Source="{Binding Source={x:Reference _pageView}, Path=BindingContext.Images.Image}">
                                    <Image.Triggers>
                                        <DataTrigger TargetType="Image" Binding="{Binding IsSelected}" Value="True">
                                            <Setter Property="IsVisible" Value="True"/>
                                        </DataTrigger>
                                        <DataTrigger TargetType="Image" Binding="{Binding IsSelected}" Value="False">
                                            <Setter Property="IsVisible" Value="False"/>
                                        </DataTrigger>
                                    </Image.Triggers>
                                    <Image.GestureRecognizers>
                                        <TapGestureRecognizer CommandParameter ="{Binding .}"
                                                              Tapped="_OnTapped"
                                                              NumberOfTapsRequired="1">
                                        </TapGestureRecognizer>
                                    </Image.GestureRecognizers>
                                </ffimageloading:CachedImage>

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
pumaprogcommented, Nov 3, 2017

That did it. Thank you so much for walking through it with me.

0reactions
daniel-luberdacommented, Nov 3, 2017

you must use ffimageloading:CachedImage, not CachedImage everywhere, that’s how the xaml custom controls work.

Read more comments on GitHub >

github_iconTop Results From Across the Web

bindable not an instance of AssociatedType - Xamarin.Forms
I want to change the textcolor of my Label when the Value of the Bound Property is 8. Without the Trigger in the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found