private void invoiceDateComboBox_SelectionChanged(object sender, SelectionChangedEventArgs e) { ///Disable other drop down menu's if this is selected if (invoiceDateComboBox.IsEnabled) { invoiceIDComboBox.IsEnabled = false; invoiceAmountComboBox.IsEnabled = false; } ///The two other drop down menu's will be disabled when this is being used ///When selected, this combo box will show a drop down list with invoice Dates ///The user will be able to highlight/select a date and it will be recieved ///by the dataGrid1 to show that specific invoice only /// Console.Write("textbox Value: " + invoiceDateComboBox.SelectedItem); //get query needed find invoice String sQuery = mydb.SelectInvoiceDate(invoiceDateComboBox.SelectedItem.ToString()); //datatable used to fget table data. dt = db.FillSqlDataTable(sQuery); //fill the datagrid invoiceGrid1.ItemsSource = dt.DefaultView; }