Exemplo n.º 1
0
        private void button1_Click(object sender, EventArgs e)
        {
            if (!(String.IsNullOrEmpty(RNameCliente.Text) || String.IsNullOrEmpty(RRFC.Text) || String.IsNullOrEmpty(RCalle.Text) || String.IsNullOrEmpty(RColonia.Text) || String.IsNullOrEmpty(RNumero.Text) || String.IsNullOrEmpty(RCPostal.Text) || String.IsNullOrEmpty(RMunip.Text) || String.IsNullOrEmpty(REstado.Text)))
            {
                Cliente nuevo = new Cliente();
                if (!nuevo.searchCliente(RRFC.Text))
                {
                    nuevo.creaCliente(RRFC.Text, RNameCliente.Text, RColonia.Text,RCalle.Text,RNumero.Text,RNumeroInt.Text,Convert.ToInt32(RCPostal.Text),RMunip.Text,REstado.Text, REmail.Text, RPhone.Text);
                    this.Hide();
                }
                else
                {
                    MessageBox.Show("CLIENTE YA EXISTE");
                }

            }
        }
Exemplo n.º 2
0
 private void search_Click(object sender, EventArgs e)
 {
     cliente = new Cliente();
     if (cliente.searchCliente(RFCdata.Text))
     {
         //AQUI CARGO EL CLIENTE
         RFCLabel.Text = cliente.rfc;
         ClienteLabel.Text = cliente.nombre;
         ColLabel.Text = cliente.colonia;
         CalleLabel.Text = cliente.calle;
         NumLabel.Text = cliente.numero;
         NumIntLabel.Text = cliente.numint;
         CPLabel.Text = cliente.codigopostal.ToString();
         DelMunLabel.Text = cliente.delegmunip;
         EstadoLabel.Text = cliente.estado;
         EmailLabel.Text = cliente.correo;
         TelLabel.Text = cliente.telefono;
     }
     else
     {
         cliente = null;
         RFCLabel.Text = "---";
         ClienteLabel.Text = "---";
         ColLabel.Text = "---";
         CalleLabel.Text = "---";
         NumLabel.Text = "---";
         NumIntLabel.Text = "---";
         CPLabel.Text = "---";
         DelMunLabel.Text = "---";
         EstadoLabel.Text = "---";
         EmailLabel.Text = "---";
         TelLabel.Text = "---";
         MessageBox.Show("CLIENTE NO EXISTE");
         Registro reg = new Registro(RFCdata.Text);
         reg.Show();
     }
 }
Exemplo n.º 3
0
 public Factura(Cliente c, List<Articulo> a)
 {
     this.cliente = c;
     this.arts = a;
 }