I have a custom control that has an ItemsSource
property, that I set in XAML like so:
<Controls:RadioButtonsGroup Grid.Column="1" ItemsSource="{Binding lstGender}" Orientation="Horizontal" SelectedItem="{Binding SelectedGender}" HorizontalOptions="Fill"/>
backing property:
public static readonly BindableProperty ItemsSourceProperty = BindableProperty.Create(nameof(ItemsSource), typeof(IEnumerable<object>), typeof(RadioButtonsGroup), propertyChanged: OnItemsSourceChanged);
the problem is that the OnItemsSourceChanged
method is called multiple times when I go back from the page and enter it again.