Пример #1
0
        private void table_CHUYENDI_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            var data = table_CHUYENDI.SelectedItem as CHUYENDI;

            if (data != null)
            {
                DataContext  = new DetailsTripUserControl(data.MA_CHUYENDI);
                this.Content = new DetailsTripUserControl(data.MA_CHUYENDI);
            }
        }
Пример #2
0
 //Click để xem chi tiết
 private void listPlace_MouseDoubleClick(object sender, MouseButtonEventArgs e)
 {
     if (listPlace.SelectedIndex != -1)
     {
         var data = listPlace.SelectedItem as CHUYENDI;
         if (data != null)
         {
             DataContext  = new DetailsTripUserControl(data.MA_CHUYENDI);
             this.Content = new DetailsTripUserControl(data.MA_CHUYENDI);
         }
         else
         {
             var MACD = listPlace.SelectedItem.ToString();
             MACD         = MACD.Split(',')[0];
             MACD         = MACD.Substring(MACD.IndexOf("CD"));
             DataContext  = new DetailsTripUserControl(MACD);
             this.Content = new DetailsTripUserControl(MACD);
         }
     }
 }
Пример #3
0
 private void back_button(object sender, MouseButtonEventArgs e)
 {
     DataContext  = new DetailsTripUserControl(maCD);
     this.Content = new DetailsTripUserControl(maCD);
 }