This paste brought to you by Pastebin. View Raw

  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Linq;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. using Xamarin.Forms;
  8.  
  9. namespace AwesomeApp
  10. {
  11.     public partial class MainPage : ContentPage
  12.     {
  13.         public MainPage()
  14.         {
  15.             InitializeComponent();
  16.         }
  17.  
  18.         int count = 0;
  19.         //untuk menampilkan berapa kali diklik
  20.         void Handle_Clicked(object sender, System.EventArgs e)
  21.         {
  22.             count++;
  23.             ((Button)sender).Text = $"You clicked {count} times.";
  24.         }
  25.     }
  26.  
  27.    
  28. }