예제 #1
0
        private void AtualizarListaDeClintes()
        {
            TabelaDeClientes = ControllerPessoa.CarregarListaDeNomes();

            if (TabelaDeClientes.Rows.Count != 0)
            {
                foreach (System.Data.DataRow r in TabelaDeClientes.Rows)
                {
                    foreach (System.Data.DataColumn c in TabelaDeClientes.Columns)
                    {
                        Txt_Cliente.Items.Add(r[c].ToString());
                    }
                }
            }
        }
        private void Frm_NewOrdem_Load(object sender, EventArgs e)
        {
            Txt_DataEntrada.Text = DateTime.Now.ToString("dd/MM/yy");

            //Preenchendo o ComboBox com o nome de Clientes
            TabelaDeClientes = ControllerPessoa.CarregarListaDeNomes();

            if (TabelaDeClientes.Rows.Count != 0)
            {
                foreach (System.Data.DataRow r in TabelaDeClientes.Rows)
                {
                    foreach (System.Data.DataColumn c in TabelaDeClientes.Columns)
                    {
                        Txt_Clientes.Items.Add(r[c].ToString());
                    }
                }
            }
        }
예제 #3
0
        private void AtualziarLsitaDeClientes()
        {
            Txt_Pessoa.Items.Clear();

            System.Data.DataTable tabela = new System.Data.DataTable();

            tabela = ControllerPessoa.CarregarListaDeNomes();
            if (tabela.Rows.Count != 0)
            {
                foreach (System.Data.DataRow r in tabela.Rows)
                {
                    foreach (System.Data.DataColumn c in tabela.Columns)
                    {
                        Txt_Pessoa.Items.Add(r[c].ToString());
                    }
                }

                Txt_Pessoa.Text = Txt_Pessoa.Items[0].ToString();
            }
        }
예제 #4
0
        private void AtualizarListaDeClientes()
        {
            comboBox_Clientes.Items.Clear();

            DataTable tabela = new DataTable("ListaDeNomes");

            tabela = ControllerPessoa.CarregarListaDeNomes();


            if (tabela.Rows.Count != 0)
            {
                foreach (DataRow r in tabela.Rows)
                {
                    foreach (DataColumn c in tabela.Columns)
                    {
                        comboBox_Clientes.Items.Add(r[c].ToString());
                    }
                }
                comboBox_Clientes.Text = comboBox_Clientes.Items[0].ToString();
            }
        }