发布日期:2022-05-24
using (SqlConnection conn = new SqlConnection(connStr)) { try { conn.Open; MessageBox.Show("数据连接成功"); string Sql = "select [id], [name] from [sysobjects] where [type] = 'u' order by [name]"; SqlCommand cmd = new SqlCommand(Sql, conn); Sql...