我已利用这一法典链接数据库。 正在显示错误。 连接财产尚未启动。
Dim sConnString As String = "user id=" + sUserID + ";password=" + sPwd + ";initial catalog=" + sDatabase + ";Connect Timeout = 30" + ";Pooling=true;Max Pool Size=" + MaxPoolSize + ";Min Pool Size=" + MinPoolSize + ";"
Dim Conn As New SqlConnection()
Dim cmd As New SqlCommand()
cmd.CommandText = "INSERT INTO NEC_Customer_Mst(Customer_Code,Customer_Name) VALUES(Customercode,Customername)"
cmd.Connection = Conn
Conn.Open()
cmd.ExecuteNonQuery()
Conn.Close()
任何建议?