Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SqlCommand command = conn.CreateCommand();
- command.CommandText = "select Test from PrescTest pt, Prescription p where pt.idPresc=p.idPresc";
- conn.Open();
- SqlDataReader dr2 = command.ExecuteReader();
- try
- {
- if (dr2.HasRows)
- {
- string Tests ="";
- while (dr2.Read())
- {
- // get the results of column "Test"
- Tests += dr2["Test"].ToString() + System.Environment.NewLine;
- }
- TextBox15.Text = Tests.Trim();
- conn.Close();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement