protected void Button1_Click(object sender, EventArgs e) { adminBL admin = new adminBL(); if (admin.messageInsert(DropDownList1.SelectedValue, TextBox1.Text, Label19.Text, TextBox2.Text) > 0) { DropDownList1.SelectedIndex = 0; TextBox1.Text = ""; TextBox2.Text = ""; Response.Write("<script>alert('訊息登錄成功');</script>"); } }