Example #1
0
        protected void ButtonSubmit_Click(object sender, EventArgs e)
        {
            string email  = TextBoxEmail.Text;
            int    userId = Convert.ToInt32(Session["UserId"]);

            Classes.Invite i      = new Classes.Invite();
            int            status = i.inviteSend(userId, email);

            if (status == 1)
            {
                HiddenFieldToastStatus.Value  = "1";
                HiddenFieldToastMode.Value    = "invite";
                HiddenFieldToastSmiley.Value  = ":)";
                HiddenFieldToastMessage.Value = "You have successfully sent your invitation!";
                HiddenFieldButton1Text.Value  = "OK";
                HiddenFieldButton1Color.Value = "d7432e";
            }
            else
            {
                HiddenFieldToastStatus.Value  = "1";
                HiddenFieldToastMode.Value    = "invite";
                HiddenFieldToastSmiley.Value  = ":(";
                HiddenFieldToastMessage.Value = "Something went wrong! Please try later!";
                HiddenFieldButton1Text.Value  = "OK";
                HiddenFieldButton1Color.Value = "d7432e";
            }
        }
Example #2
0
        protected void ButtonSubmit_Click(object sender, EventArgs e)
        {
            string email = TextBoxEmail.Text;
            int userId = Convert.ToInt32(Session["UserId"]);

            Classes.Invite i = new Classes.Invite();
            int status = i.inviteSend(userId, email);

            if (status == 1)
            {
                HiddenFieldToastStatus.Value = "1";
                HiddenFieldToastMode.Value = "invite";
                HiddenFieldToastSmiley.Value = ":)";
                HiddenFieldToastMessage.Value = "You have successfully sent your invitation!";
                HiddenFieldButton1Text.Value = "OK";
                HiddenFieldButton1Color.Value = "d7432e";
            }
            else
            {
                HiddenFieldToastStatus.Value = "1";
                HiddenFieldToastMode.Value = "invite";
                HiddenFieldToastSmiley.Value = ":(";
                HiddenFieldToastMessage.Value = "Something went wrong! Please try later!";
                HiddenFieldButton1Text.Value = "OK";
                HiddenFieldButton1Color.Value = "d7432e";
            }
        }
Example #3
0
        protected void ButtonSubmit_Click(object sender, EventArgs e)
        {
            string email = TextBoxEmail.Text;
            string name = TextBoxName.Text;
            string message = TextBoxMessage.Text;
            int userId = Convert.ToInt32(Session["UserId"]);
            int type = 1;

            Classes.Invite i = new Classes.Invite();
            int status = i.inviteSend(userId, email, name, message, type);

            if (status == 1)
            {
                LabelStatus.Visible = true;
                LabelStatus.Text = "You have successfully sent your invitation.";
            }
            else
            {
                LabelStatus.Visible = true;
                LabelStatus.Text = "Something went wrong!";
            }
        }
Example #4
0
        protected void ButtonSubmit_Click(object sender, EventArgs e)
        {
            string email   = TextBoxEmail.Text;
            string name    = TextBoxName.Text;
            string message = TextBoxMessage.Text;
            int    userId  = Convert.ToInt32(Session["UserId"]);
            int    type    = 1;

            Classes.Invite i      = new Classes.Invite();
            int            status = i.inviteSend(userId, email, name, message, type);

            if (status == 1)
            {
                LabelStatus.Visible = true;
                LabelStatus.Text    = "You have successfully sent your invitation.";
            }
            else
            {
                LabelStatus.Visible = true;
                LabelStatus.Text    = "Something went wrong!";
            }
        }