示例#1
0
        private void Service_BookPlace(object sender, BookPlaceCompletedEventArgs e)
        {
            SingletonQuery.QueryClient.BookPlaceCompleted -= this.Service_BookPlace;

            if (e.Error == null)
            {
                this.userSeats = e.Result;

                foreach (var seat in this.userSeats)
                {
                    MessageBox.Show(string.Format("You successfully booked the seat at row {0} and position {1}",
                                                  seat.Row, seat.Position), "Information", MessageBoxButton.OK);
                }

                this.userSeats.Clear();
                this.seatsContainer.Children.Clear();
                this.PlaceSeats();
            }
        }
示例#2
0
        private void Service_BookPlace(object sender, BookPlaceCompletedEventArgs e)
        {
            SingletonQuery.QueryClient.BookPlaceCompleted -= this.Service_BookPlace;

            if (e.Error == null)
            {
                this.userSeats = e.Result;

                foreach (var seat in this.userSeats)
                {
                    MessageBox.Show(string.Format("You successfully booked the seat at row {0} and position {1}",
                           seat.Row, seat.Position), "Information", MessageBoxButton.OK);
                }

                this.userSeats.Clear();
                this.seatsContainer.Children.Clear();
                this.PlaceSeats();
            }
        }