public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { if (value != null) { FreqPlanInfo freq = value as FreqPlanInfo; return(freq.Freq_Low / 1000000 + "-" + freq.Freq_High / 1000000); } return(null); }
private void FreqCount_Click(object sender, RoutedEventArgs e) { Hyperlink hy = sender as Hyperlink; if (hy.DataContext != null) { FreqPlanInfo freqplan = hy.DataContext as FreqPlanInfo; if (freqplan.Freq_Count > 0) { EquipmentListDialog equlistdialog = new EquipmentListDialog(this.PlaceGuid, freqplan.Businesstype.Guid); equlistdialog.ShowDialog(this); } else { MessageBox.Show("当前业务类型下没有设备", "提示", MessageBoxButton.OK); } } }