Ejemplo n.º 1
0
        private void button1_Click(object sender, EventArgs e)
        {
            ProdutoS produtoS = new ProdutoS();

            //produtoS.id = Convert.ToInt32(txtId.Text);
            produtoS.nome   = txtNome.Text;
            produtoS.precoc = txtPrecoC.Text.Replace(",", ".");
            produtoS.precov = txtPrecoV.Text.Replace(",", ".");

            if (produtoS.validaCampos() == true)
            {
                produtoS.salvar(txtId.Text);
                this.limpaCampos();
            }
        }