Example #1
0
    protected void btnAgregar_Click(object sender, EventArgs e)
    {
        DateTime             fecha;
        string               nombreCliente;
        List <LineasFactura> L = (List <LineasFactura>)Session["Lineas"];
        Factura              F;

        try
        {
            fecha         = Convert.ToDateTime(txtFecha.Text);
            nombreCliente = txtNombreCliente.Text;

            F = new Factura(fecha, nombreCliente, L);
            FabricaLogica.getLogicaFactura().AgregarFactura(F);
            lblError.Text = "Alta con Exito";

            LimpiarFormulario();
        }
        catch (Exception ex)
        {
            lblError.Text = ex.Message;
        }
    }