3

I am developing excel report using DynamicJasper API. I am able to generate the report from the given datasource, but the columns in the report still appeared very narrow. I searched to get a solution for this, in many place people answer with setUseFullPageWidth(true); in DynamicReportBuilder . I tried this, but it does not resolve my issue.

Jacob Schoen
  • 14,034
  • 15
  • 82
  • 102
Ajil Mohan
  • 7,299
  • 2
  • 18
  • 18

1 Answers1

1

Use: setWidth(Integer)

    AbstractColumn[] startColsParams = {
            ColumnBuilder.getNew().setColumnProperty(new ColumnProperty(KEY_AA_ID, String.class.getName()))
                .setWidth(new Integer(40)).setTitle("AA").setStyle(style).build(),
            ColumnBuilder.getNew().setColumnProperty(new ColumnProperty(KEY_BB_ID, String.class.getName()))
                .setWidth(new Integer(160)).setTitle("BB").setStyle(style).build(),             
    };
martinnovoty
  • 896
  • 8
  • 17