Beispiel #1
0
        void FirstLoad()
        {
            variable = 0;

            //Form
            this.Size = new System.Drawing.Size(800, 600);

            //Button "Принят"
            button1.SetBounds(25, 90, 150, 80);

            //Button "Склад"
            button2.SetBounds(25, 90 + 80 + 90, 150, 80);

            //Button "Продан"
            button3.SetBounds(25, 90 + 80 + 90 + 80 + 90, 150, 80);

            //DataGridView
            dataGridView1.SetBounds(220, 10, 560, 500);
            RefreshDataGridView(DataFromDB);

            //Label "Всего позиций"
            label1.Location = new System.Drawing.Point(220, 510 + 10);
            label1.Text     = "Всего записей: " + dataGridView1.Rows.Count;

            //Button "Добавить позицию"
            button4.SetBounds(450, 530, 100, 30);

            //Button "Отфильтровать по датам"
            button5.SetBounds(450 + 100 + 100, 530, 110, 30);
        }
 private void ajustarBotoes()
 {
     try
     {
         if (m_btAnularSelecao.Visible == false)
         {
             m_btNovo.SetBounds(m_btNovo.Location.X + 16, m_btNovo.Location.Y, m_btNovo.Width, m_btNovo.Height);
             m_btEditar.SetBounds(m_btEditar.Location.X + 16, m_btEditar.Location.Y, m_btEditar.Width, m_btEditar.Height);
             m_btExcluir.SetBounds(m_btExcluir.Location.X + 16, m_btExcluir.Location.Y, m_btExcluir.Width, m_btExcluir.Height);
         }
     }
     catch (Exception err)
     {
         Object erro = err;
         m_cls_ter_tratadorErro.trataErro(ref erro);
     }
 }