,我發現了以下錯誤:HTTP 404錯誤與Response.Redirect的
HTTP Error 404.0 - Not Found The resource you are looking for has been removed, had its name changed, or is temporarily unavailable
用下面的代碼:
SqlConnection cn = new SqlConnection(@"Data Source=bpnaidu-pc\sqlexpress;Initial Catalog=UserLogIn;Integrated Security=True;Pooling=False");
cn.Open();
SqlCommand cmd = new SqlCommand("INSERT INTO regd values('" + ddl_signup.Text + "','" + txt_user.Text + "','" + txtEmail1.Text+ "','" + txtPassword.Text + "','" + txtConPassword.Text + "')", cn);
cmd.ExecuteNonQuery();
Response.Redirect("welcome to "+txt_user.Text.ToString());
Response.Redirect("Home.aspx");
cn.Close();
問題出在哪裏?
是的,這個Responce.Write工作。謝謝回覆... – Sankar