Ejemplo n.º 1
0
        private void button1_Click(object sender, EventArgs e)
        {
            DateTime date = dateTimePicker1.Value.Date;

            //events = UnionRepository.GetListOfEvents()

            dataGridView1.DataSource = UnionConverter.EvetsListToTable(events).DefaultView;
            dataGridView1.Visible    = true;
            button1.Visible          = true;
            button3.Visible          = true;
            button4.Visible          = true;
        }
Ejemplo n.º 2
0
        private void button1_Click_1(object sender, EventArgs e)
        {
            button3.Visible         = true;
            button4.Visible         = true;
            label1.Visible          = true;
            label2.Visible          = true;
            label3.Visible          = true;
            textBox1.Visible        = true;
            textBox2.Visible        = true;
            dateTimePicker2.Visible = true;
            dataGridView1.Visible   = true;
            button6.Visible         = true;
            //WindowsFormsApp.Events.AddEvent(textBox1.Text, textBox2.Text, dateTimePicker2.Value.Date);

            UnionRepository.AddEvent(new UnionEvent(0, textBox1.Text, dateTimePicker2.Value.Date, textBox2.Text));
            events = UnionRepository.GetListOfEvents();
            dataGridView1.DataSource = UnionConverter.EvetsListToTable(events).DefaultView;

            //dataGridView1.DataSource = DataBase.GetEvents().DefaultView;
        }