qdrow

Untitled

Sep 20th, 2019
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.10 KB | None | 0 0
  1. /// <summary>
  2. /// Логика взаимодействия для MainWindow.xaml
  3. /// </summary>
  4. public partial class MainWindow : Window
  5. {
  6. public bool comma = false;
  7. public MainWindow()
  8. {
  9. InitializeComponent();
  10. }
  11.  
  12. private void Numbers(object sender, RoutedEventArgs e)
  13. {
  14. Button Any_but = (Button)sender;
  15. switch (Any_but.Content)
  16. {
  17. case "0":
  18. if (Tablo.Text != "0")
  19. {
  20. Tablo.Text += "0";
  21. }
  22. break;
  23. default:
  24. if (Tablo.Text == "0")
  25. {
  26. Tablo.Text = Convert.ToString(Any_but.Content);
  27. }
  28. else
  29. {
  30. Tablo.Text += Any_but.Content;
  31. }
  32. break;
  33.  
  34.  
  35. }
  36. }
  37. private void Comma_Click(object sender, RoutedEventArgs e)
  38. {
  39.  
  40. }
  41. }
Advertisement
Add Comment
Please, Sign In to add comment