Closed Croseven closed 6 years ago
I have the following in XAML
<local:CircleButton WidthRequest="50" HeightRequest="50" x:Name="btnRegisterHorse" BorderColor="#1976D2" BackgroundColor="#1976D2" BorderRadius="20"></local:CircleButton>
and the following in CS btnRegisterHorse.Icon = "register_foul.png";
btnRegisterHorse.Icon = "register_foul.png";
Then it causes my app to crash with the following StackTrace StackTrace.txt
This is not the correct way to show an image. If you want to show an image you must use the Image property like this:
Image
btnRegisterHorse.Image = "register_foul.png";
I have the following in XAML
<local:CircleButton WidthRequest="50" HeightRequest="50" x:Name="btnRegisterHorse" BorderColor="#1976D2" BackgroundColor="#1976D2" BorderRadius="20"></local:CircleButton>
and the following in CS
btnRegisterHorse.Icon = "register_foul.png";
Then it causes my app to crash with the following StackTrace StackTrace.txt