Esempio n. 1
0
        private void CXC_007_Rpt_BeforePrint(object sender, System.Drawing.Printing.PrintEventArgs e)
        {
            lbl_fecha.Text   = DateTime.Now.ToString("dd/MM/yyyy hh:mm:ss");
            lbl_empresa.Text = empresa;
            lbl_usuario.Text = usuario;

            int     IdEmpresa     = string.IsNullOrEmpty(p_IdEmpresa.Value.ToString()) ? 0 : Convert.ToInt32(p_IdEmpresa.Value);
            int     IdSucursal    = string.IsNullOrEmpty(p_IdSucursal.Value.ToString()) ? 0 : Convert.ToInt32(p_IdSucursal.Value);
            decimal IdLiquidacion = string.IsNullOrEmpty(p_IdLiquidacion.ToString()) ? 0 : Convert.ToDecimal(p_IdLiquidacion.Value);

            CXC_007_Bus         bus_rpt = new CXC_007_Bus();
            List <CXC_007_Info> lst_rpt = bus_rpt.GetList(IdEmpresa, IdSucursal, IdLiquidacion);

            this.DataSource = lst_rpt;


            tb_empresa_Bus bus_empresa = new tb_empresa_Bus();
            var            emp         = bus_empresa.get_info(IdEmpresa);

            if (emp != null && emp.em_logo != null)
            {
                ImageConverter obj = new ImageConverter();
                lbl_imagen.Image = (Image)obj.ConvertFrom(emp.em_logo);
            }
        }
Esempio n. 2
0
        private void CXC_007_Rpt_BeforePrint(object sender, System.Drawing.Printing.PrintEventArgs e)
        {
            lbl_fecha.Text   = DateTime.Now.ToString("dd/MM/yyyy hh:mm:ss");
            lbl_empresa.Text = empresa;
            lbl_usuario.Text = usuario;

            int     IdEmpresa     = string.IsNullOrEmpty(p_IdEmpresa.Value.ToString()) ? 0 : Convert.ToInt32(p_IdEmpresa.Value);
            int     IdSucursal    = string.IsNullOrEmpty(p_IdSucursal.Value.ToString()) ? 0 : Convert.ToInt32(p_IdSucursal.Value);
            decimal IdLiquidacion = string.IsNullOrEmpty(p_IdLiquidacion.ToString()) ? 0 : Convert.ToDecimal(p_IdLiquidacion.Value);

            CXC_007_Bus         bus_rpt = new CXC_007_Bus();
            List <CXC_007_Info> lst_rpt = bus_rpt.GetList(IdEmpresa, IdSucursal, IdLiquidacion);

            this.DataSource = lst_rpt;
        }