Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var select = "select cardnumber,[status],cp.name_series,print_name,print_surname,embg_user from cards_issued c join card_products cp on c.idproduct=cp.idproduct where embg_user='" + txtembg.Text + "'";
- var c = new SqlConnection("Data Source=WIN-3QUAK81995Q;Initial Catalog=lt-2;Persist Security Info=True;User ID=lt-2;Password=lt-2P@ssw0rd"); // Your Connection String here
- var dataAdapter = new SqlDataAdapter(select, c);
- var commandBuilder = new SqlCommandBuilder(dataAdapter);
- var ds = new DataSet();
- dataAdapter.Fill(ds);
- dataGridView1.ReadOnly = true;
- dataGridView1.DataSource = ds.Tables[0];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement