예제 #1
0
        protected void btnSubmit_Click(object sender, EventArgs e)
        {
            VsrDataContext db = new VsrDataContext();
            ContactMessage m = new ContactMessage();

            m.message_id = Guid.NewGuid();
            m.sender_ip = Request.UserHostAddress;
            m.name = txtName.Text.ToString();
            m.email = txtEmail.Text.ToString();
            m.sent = DateTime.Now;
            m.message = txtMessage.Text.ToString();
            db.ContactMessages.InsertOnSubmit(m);
            db.SubmitChanges();

            txtEmail.Text = "";
            txtMessage.Text = "";
            txtName.Text = "";

            mv1.ActiveViewIndex = 1;
 
        }
예제 #2
0
 partial void DeleteContactMessage(ContactMessage instance);
예제 #3
0
 partial void UpdateContactMessage(ContactMessage instance);
예제 #4
0
 partial void InsertContactMessage(ContactMessage instance);