string str = "Data Source=.;Initial Catalog=GuestBook;Integrated Security=True";
string time = Convert.ToString(DateTime.Now.ToLongTimeString());
SqlConnection myConnection = new SqlConnection(str);
myConnection.Open();
string sqlstr = "insert into GusetBookInfo(Name,Detail,Time) values ('" + this.name0.Text
+ "' , '" + this.comment0.Text + "' ,'" + time + "','')";
SqlCommand com = new SqlCommand(sqlstr, myConnection);
myConnection.Close();
com.Connection.Open();
com.ExecuteNonQuery();
Response.Write("");
你数据库里面没有这个数据表 没有找到这个表
①连接的数据库地址不对 数据库里面没有这个表。
②数据表的名字打错了,表名不对。
GuestBookInfo,你敲错字了