Пример #1
0
        public Document Customizar(FwRelatorioDados data, string fonte = "Verdana", bool mostrarLogo = true)
        {
            Configurar(data);
            CriarCabecalho(fonte, mostrarLogo);
            CriarRodape();

            return(_document);
        }
Пример #2
0
 public byte[] Gerar(FwRelatorioDados data, string fonte = "Verdana", bool mostrarLogo = true)
 {
     Configurar(data);
     CriarCabecalho(fonte, mostrarLogo);
     CriarTabela(fonte);
     CriarTextosPosTabela(fonte);
     CriarRodape();
     return(Renderizar());
 }
Пример #3
0
        private void Configurar(FwRelatorioDados data)
        {
            _dataSource           = data;
            _document.Info.Title  = data.Titulo;
            _document.Info.Author = "FwLog Web";

            Section section = _document.AddSection();

            section.PageSetup.Orientation    = _dataSource.Orientacao;
            section.PageSetup.PageFormat     = PageFormat.A4;
            section.PageSetup.HeaderDistance = new Unit(10, UnitType.Point);
            section.PageSetup.FooterDistance = new Unit(10, UnitType.Point);
            section.PageSetup.LeftMargin     = new Unit(40, UnitType.Point);
            section.PageSetup.RightMargin    = new Unit(40, UnitType.Point);
            section.PageSetup.TopMargin      = new Unit(90, UnitType.Point);
        }