1. Command介绍�0�1 Dispose()�0�1 CommandText�0�1 构造函数()SqlConnection conn = new SqlConnection(); conn.ConnectionString = "server=KEVIN-LI;database=ADONET;uid=admin;pwd=123456"; //打开连接薯纳 conn.Open(); //执判手蠢行命令 SqlCommand cmd = new SqlCommand(); cmd.Connection = conn; string sql = "select * from 销售记录掘陪表"; cmd.CommandText = sql; SqlDataReader dr = cmd.ExecuteReader(); if (dr.Read()) { dr.Read(); dr.Read(); MessageBox.Show(dr.GetString(1)); } conn.Close(); conn.Dispose();