Am new to DynamicReportBuilder
and want to add a new column to list the serial number of the total rows coming from the db.
Currently, I have researched through ColumnBuilder
but, wasn't able to find a feasible solution. I have tried this for now,
ColumnBuilder serialNo = ColumnBuilder.getNew();
serialNo.setTitle("S No.");
serialNo.setWidth(60);
serialNo.setFixedWidth(true);
logger.info(count+" Total Records");//Count is the total no of rows
for (int j=1;j<count;j++) {
serialNo.setColumnProperty(j+"",String.class.getName(),j+"");
}
dynamicReportBuilder.addColumn(serialNo.build());
But the problem with this is, it is only showing the last count in the serial number row. Something like this:
S. No.
3
3
3
3