// Edit
        protected void lbSaveCamp_Click(object sender, EventArgs e)
        {
            try
            {
                string campName = txtEditCampName.Text.ToString();
                DataTable dtCheck = CampaignBase.SelectByField("CampaignsName", txtEditCampName.Text.ToString(), ConnectionString);
                Campaign objCampaign = new Campaign(ConnectionString);
                objCampaign.CampaignsName = txtEditCampName.Text;
                objCampaign.CampaignsDesc = txtEditCampDescription.Text;
                if (Convert.ToInt64(hiddenEditID.Value) > 0)
                {
                    objCampaign.ID = Convert.ToInt64(hiddenEditID.Value);
                    if (dtCheck.Rows.Count > 0 && Convert.ToInt64(dtCheck.Rows[0]["ID"]) != Convert.ToInt64(hiddenEditID.Value))
                    {
                        lbMsgForEdit.Text = "Campaign:" + txtEditCampName.Text + ",  already exists. Please enter other name.";
                        MpextDivEdit.Show();
                    }
                    else
                    {
                        CampaignPrimaryKey pk = new CampaignPrimaryKey(Convert.ToInt64(hdId.Value.ToString()));
                        Campaign CampNew = Campaign.SelectOne(pk, ConnectionString);
                        Campaign = new Campaign(ConnectionString);
                        Campaign.ID = Convert.ToInt64(hdId.Value.ToString());
                        Campaign.CampaignsName = txtEditCampName.Text.ToString().Trim();
                        Campaign.CampaignsDesc = txtEditCampDescription.Text.ToString().Trim();
                        Campaign.CreatedDate = CampNew.CreatedDate;
                        Campaign.ModifiedDate = DateTime.Now;
                        Campaign.Active = true;
                        if (Campaign.Update() == true)
                        {

                            lblMainMsg.Text = string.Format("Campaign: {0} Updated Successfully.", Server.HtmlEncode(txtEditCampName.Text));
                            bindGrid(string.Empty, RGridCampMails.CurrentPageIndex);
                        }
                        else
                        {
                            lblMainMsg.Text = string.Format("Campaign: {0} Updation Failed.", Server.HtmlEncode(txtEditCampName.Text));
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }