Exemple #1
0
        public AmountPage()
        {
            Title        = "Amount";
            _amountLabel = new Label
            {
                Text = $"Your current bank account {_amount}",
                HorizontalOptions = LayoutOptions.CenterAndExpand,
                VerticalOptions   = LayoutOptions.CenterAndExpand
            };
            Content = new StackLayout
            {
                Children =
                {
                    _amountLabel
                }
            };

            _serverConnectionHelper = new ServerConnectionHelper();

            TriggerTimer();
        }
 public RequestPage()
 {
     Title        = "Request";
     _amountEntry = new Entry {
         HorizontalOptions = LayoutOptions.CenterAndExpand, VerticalOptions = LayoutOptions.CenterAndExpand, WidthRequest = 300, Text = ""
     };
     _serverConnectionHelper = new ServerConnectionHelper();
     Content = new StackLayout
     {
         HorizontalOptions = LayoutOptions.CenterAndExpand,
         VerticalOptions   = LayoutOptions.CenterAndExpand,
         Children          =
         {
             new Label  {
                 Text = "Requested amount", HorizontalOptions = LayoutOptions.CenterAndExpand, VerticalOptions = LayoutOptions.StartAndExpand
             },
             _amountEntry,
             new Button {
                 Text = "Make request", Command = new Command(async() => ExecuteMoneyRequest()), HorizontalOptions = LayoutOptions.CenterAndExpand, VerticalOptions = LayoutOptions.EndAndExpand
             }
         }
     };
 }