Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- MySqlCommand serialBox_1 = new MySqlCommand("Select serial_Units from Units where " + stationSelection_1 = "station_Units", connection);
- public MainWindow()
- {
- InitializeComponent();
- string connectionString = "SERVER=localhost;DATABASE=dbname; UID=myPC;Password=mypw;";
- MySqlConnection connection = new MySqlConnection(connectionString);
- MySqlCommand stationList = new MySqlCommand("Select stationNumber_stations from stations", connection);
- connection.Open();
- DataTable dt_stations = new DataTable();
- dt_stations.Load(stationList.ExecuteReader());
- connection.Close();
- stationComboBox_1.DataContext = dt_stations;
- stationComboBox_1.ItemsSource = dt_stations.DefaultView;
- string stationSelection_1 = stationComboBox_1.Text;
- MySqlCommand serialBox_1 = new MySqlCommand("Select serial_Units from Units where " + stationSelection_1 = "station_Units", connection);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement