Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- MySqlConnection con = new MySqlConnection("datasource=localhost;port=3306;database=meal;username=root;password=july241998");
- string query1 = $"SELECT title from recipe where budget = listBox.SelectedItem";
- MySqlCommand cmd1 = new MySqlCommand(query1, con);
- con.Open();
- MySqlDataReader dr1 = cmd1.ExecuteReader();
- while (dr1.Read())
- {
- richtextBox.Append = dr1.GetString("budget");
- }
- con.Close();
Add Comment
Please, Sign In to add comment