Example #1
0
        private void botonIngresar_MouseClick_1(object sender, MouseEventArgs e)
        {
            String           ruc         = this.textBoxRuc.Text;
            String           razonSocial = this.textBoxRazonSocial.Text;
            String           direccion   = this.textBoxDireccion.Text;
            String           correo      = this.textBoxCorreo.Text;
            String           telfconv    = this.textBoxTelefonoConvencional.Text;
            String           telfCel     = this.textBoxTelefonoCelular.Text;
            controlProveedor cp          = new controlProveedor();

            if (cp.existeProveedor((this.textBoxRuc.Text), "RUC").Equals("vacio"))
            {
                cp.RregistrarProveedor(ruc, razonSocial, direccion, correo, telfconv, telfCel);
                //MessageBox.Show("Proveedor registrado correctamente");
                textBoxCorreo.Text               = "";
                textBoxRazonSocial.Text          = "";
                textBoxDireccion.Text            = "";
                textBoxRuc.Text                  = "";
                textBoxTelefonoCelular.Text      = "";
                textBoxTelefonoConvencional.Text = "";
            }
            else
            {
                MessageBox.Show("Proveedor ya se encuentra registrado");
            }
        }