Example #1
0
        public MonthlyReportPreferencesForm()
        {
            InitializeComponent();

            //Opens all email address and reports
            clsEmailAddr.openAll();
            clsMonthlyReports.openWhere("");

            //Add the tags to the recipients column
            dataGridViewReicpitents.Columns[0].Tag = "ActiveReportRecipeint";
            dataGridViewReicpitents.Columns[2].Tag = "RecipientName";
            dataGridViewReicpitents.Columns[3].Tag = "EmailAddress";

            //Fills reports
            fillReports();
            //Fills Recipients
            fillRecipients(true);
            //Done loading values
            loadingValues = false;
        }
Example #2
0
        private void btnInsert_Click(object sender, EventArgs e)
        {
            DataRow drow = clsEmailAddresses.DSet.Tables[0].NewRow();

            drow["RecipientName"] = tbName.Text;
            drow["EmailAddress"]  = tbEmailAddress.Text;
            drow["CreatedBy"]     = CCFBGlobal.dbUserName;
            drow["Created"]       = DateTime.Now.ToString();

            clsEmailAddresses.DSet.Tables[0].Rows.Add(drow);

            clsEmailAddresses.insert();
            clsEmailAddresses.openAll();

            frmEmailRecpt.fillRecipients(true);

            this.Close();
        }