private async void AddOneBottleButton_Click(object sender, EventArgs e) { var sendSuccessfully = await Infrastructure.AddBottles(this._inventoryId, this._currentAmount, int.Parse(this.tbamount.Text), this._shelfId); if (sendSuccessfully.ErrorCode) { var responseObject = (InventoryResponse)sendSuccessfully.Object; this.CurrentAmount = responseObject.Amount.ToString(); } else if (!string.IsNullOrEmpty(sendSuccessfully.Message)) { MessageBox.Show(sendSuccessfully.Message, "Fel"); } }