public async void CheckOutBook() { if (!PerformCheckOutValidation()) { DisplayErrorMessage(BookCheckOutConditionError); return; } var transaction = new BookTransaction { Customer = new Customer { CustomerId = SuppliedCustomerId }, Book = new Book { BookId = SelectedBook.BookId }, CheckOut = DateTime.Now }; bool success = await bookManager.CheckOutBook(transaction).ConfigureAwait(false); SuppliedCustomerId = 0; OnPropertyChanged("SuppliedCustomerId"); if (success) { --SelectedBook.AvailableCopies; CollectionViewSource.GetDefaultView(this.Books).Refresh(); DisplayInfoMessage(BookCheckOutSuccess, "Success!"); } else { DisplayErrorMessage(BookCheckOutError); } }