Я пытаюсь отобразить, отобразить предупреждение, когда я нажимаю «OnLogOut», но это не беспокоит, и я не могу понять, почему
<StackLayout Grid.Row="1" BackgroundColor="White" HorizontalOptions="FillAndExpand" Orientation="Vertical" VerticalOptions="FillAndExpand" Spacing="30" Padding="0,0,0,0">
<StackLayout Orientation="Horizontal" HorizontalOptions="Center">
<!--Le text est dans la classe-->
<Label x:Name="myemail" Text="" TextColor="#36688D" Font="Bold,Italic,20" />
</StackLayout>
<StackLayout Orientation="Horizontal" HorizontalOptions="Center">
<Label HorizontalOptions="Center"
TextColor="#36688D"
FontSize="15"
Text="Log Out" x:Name="mylogout">
<Label.GestureRecognizers>
<TapGestureRecognizer Tapped="OnLogOut" />
</Label.GestureRecognizers>
</Label>
</StackLayout>
</StackLayout>
Вот мой код c #:
public async void OnLogOut(object sender, EventArgs args)
{
Console.WriteLine("Log out is tapped");
await DisplayAlert("Email", "Your email please", "✔");
}
заранее спасибо