Metziop

Untitled

May 24th, 2023
785
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.84 KB | None | 0 0
  1.  private async void Calcular_Clicked(object sender, EventArgs e)
  2.         {
  3.             try
  4.             {
  5.                 double x1 = Convert.ToDouble(txtX1.Text);
  6.                 double x2 = Convert.ToDouble(txtX2.Text);
  7.                 double r1 = Convert.ToDouble(txtR1.Text);
  8.                 double y1 = Convert.ToDouble(txtY1.Text);
  9.                 double y2 = Convert.ToDouble(txtY2.Text);
  10.                 double r2 = Convert.ToDouble(txtR2.Text);
  11.                 await Navigation.PushModalAsync(new Resulltado(x1, x2, y1, y2, r1, r2));
  12.  
  13.             }
  14.             catch (FormatException)
  15.             {
  16.                 await DisplayAlert("Error", "Debe ingresar todos los valores requeridos", "OK");
  17.  
  18.             }
  19.             catch (Exception ex) {
  20.                 await DisplayAlert("Error", ex.Message, "OK");
  21.             }
  22.  
  23.         }
Advertisement
Add Comment
Please, Sign In to add comment