Exemple #1
0
        public async void DB()
        {
            BD_Edit edit             = new BD_Edit();
            string  connectionString = @"Data Source = DESKTOP-EPNEITS; Initial Catalog = " + Program.server + "; Integrated Security = True";

            sqlConnection = new SqlConnection(connectionString);

            await sqlConnection.OpenAsync();

            edit.LoadDataCritery();
            SqlConnection connect = new SqlConnection(connectionString);
            string        podkl   = "SELECT * FROM critery";
            SqlCommand    com     = new SqlCommand(podkl, connect);

            connect.Open();
            SqlDataReader read = com.ExecuteReader();

            tabl.Load(read);
        }  // Подключение к БД