private void btnAccountLogIn_Click_1(object sender, EventArgs e)
 {
     Hide();
     Form2_FacilitatorLogin form2 = new Form2_FacilitatorLogin();
     form2.Closed += (s, args) => Close();
     form2.Show();
 }
Example #2
0
        private void btnAccountLogIn_Click_1(object sender, EventArgs e)
        {
            Hide();
            Form2_FacilitatorLogin form2 = new Form2_FacilitatorLogin();

            form2.Closed += (s, args) => Close();
            form2.Show();
        }
Example #3
0
        private void btnLogout_Click(object sender, EventArgs e)
        {
            DialogResult dialogResult = System.Windows.Forms.MessageBox.Show("Are you sure you want to Log-out?", "Log-out Confirmation", MessageBoxButtons.YesNo);

            if (dialogResult == DialogResult.Yes)  // error is here
            {
                this.Hide();
                Form2_FacilitatorLogin form2 = new Form2_FacilitatorLogin();
                form2.Closed += (s, args) => this.Close();
                form2.Show();
            }
        }
        /*
         * private void btnCreatePDF_Click(object sender, EventArgs e)
         * {
         *  exportToPDF(facilitatorTableAdapter.GetData());
         *  MessageBox.Show("Print Success.");
         * }
         *
         * private void exportToPDF(DataTable dt)
         * {
         *  using (Document document = new Document())
         *  {
         *      string title = "System Report (Facilitator)_" + DateTime.Now.ToString("MM-dd-yyyy") + ".pdf";
         *      using (PdfWriter writer = PdfWriter.GetInstance(document, new FileStream(title, FileMode.Create)))
         *      {
         *          HeaderFooter hf = new HeaderFooter();
         *          writer.SetBoxSize("art", new Rectangle(36, 54, 220, 820));
         *          writer.PageEvent = hf;
         *          document.Open();
         *          Font font5 = FontFactory.GetFont(FontFactory.HELVETICA, 5);
         *          PdfPTable table = new PdfPTable(dt.Columns.Count);
         *          float[] widths = new float[] { 4f, 4f, 4f, 4f, 4f };
         *          table.SetWidths(widths);
         *          table.WidthPercentage = 100;
         *          PdfPCell cell = new PdfPCell(new Phrase("Facilitators"));
         *          cell.Colspan = dt.Columns.Count;
         *          foreach (DataColumn c in dt.Columns)
         *          {
         *              table.AddCell(new Phrase(c.ColumnName, font5));
         *          }
         *          foreach (DataRow r in dt.Rows)
         *          {
         *              if (dt.Rows.Count > 0)
         *              {
         *                  table.AddCell(new Phrase(r[0].ToString(), font5));
         *                  table.AddCell(new Phrase(r[1].ToString(), font5));
         *                  table.AddCell(new Phrase(r[2].ToString(), font5));
         *                  table.AddCell(new Phrase(r[3].ToString(), font5));
         *                  table.AddCell(new Phrase(r[4].ToString(), font5));
         *              }
         *          }
         *          document.Add(table);
         *          document.Close();
         *      }
         *  }
         * }
         */
        private void btnLogout_Click(object sender, EventArgs e)
        {
            DialogResult dialogResult = MessageBox.Show("Are you sure you want to Log-out?", "Confirm Logout", MessageBoxButtons.YesNo);

            if (dialogResult == DialogResult.Yes)  // error is here
            {
                Hide();
                Form2_FacilitatorLogin form2 = new Form2_FacilitatorLogin();
                form2.Closed += (s, args) => Close();
                form2.Show();
            }
        }
        private void btnLogout_Click_1(object sender, EventArgs e)
        {
            DialogResult dialogResult = MessageBox.Show("Are you sure you want to Log-out?", "Confirm Logout", MessageBoxButtons.YesNo);
            if (dialogResult == DialogResult.Yes)  // error is here
            {
                Hide();
                Form2_FacilitatorLogin form2 = new Form2_FacilitatorLogin();
                form2.Closed += (s, args) => Close();
                form2.Show();
            }

        }
        private void btnLogout_Click(object sender, EventArgs e)
        {
            DialogResult dialogResult = System.Windows.Forms.MessageBox.Show("Are you sure you want to Log-out?", "Log-out Confirmation", MessageBoxButtons.YesNo);

            if (dialogResult == DialogResult.Yes)  // error is here
            {
                this.Hide();
                Form2_FacilitatorLogin form2 = new Form2_FacilitatorLogin();
                form2.Closed += (s, args) => this.Close();
                form2.Show();
            }

        }