private void putRow(HSSFCellStyle cellStyle,HSSFCellStyle cellStyleD,HSSFCellStyle cellStyleN,HSSFSheet sheet,HSSFRow row,int fila,ReportTO rpt){
  HSSFRichTextString text;
  short col=0;
  cellStyle.setAlignment(HSSFCellStyle.ALIGN_RIGHT);
  text=new HSSFRichTextString(rpt.getName());
  HSSFCell cell=row.createCell(col++);
  cell.setCellStyle(cellStyleN);
  cell.setCellValue(text);
  text=new HSSFRichTextString(rpt.getDescription());
  cell.setCellStyle(cellStyleD);
  cell=row.createCell(col++);
  cell.setCellValue(text);
  if (cols >= 3) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_0()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 4) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_1()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 5) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_2()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 6) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_3()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 7) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_4()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 8) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_5()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 9) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_6()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 10) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_7()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 11) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_8()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 12) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_9()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 13) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_10()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 14) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_11()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 15) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_12()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 16) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_13()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 17) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_14()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 18) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_15()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 19) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_16()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 20) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_17()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 21) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_18()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 22) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_19()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
  if (cols >= 23) {
    text=new HSSFRichTextString(formatValue(rpt.getCol_20()));
    cell=row.createCell(col++);
    cell.setCellStyle(cellStyle);
    cell.setCellValue(text);
  }
}

private void putRow ( HSSFCellStyle cellStyle , HSSFCellStyle cellStyleD , HSSFCellStyle cellStyleN , HSSFSheet sheet , HSSFRow row , int fila , ReportTO rpt ) { HSSFRichTextString text ; short col = 0 ; cellStyle . setAlignment ( HSSFCellStyle . ALIGN_RIGHT ) ; text = new HSSFRichTextString ( rpt . getName ( ) ) ; HSSFCell cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyleN ) ; cell . setCellValue ( text ) ; text = new HSSFRichTextString ( rpt . getDescription ( ) ) ; cell . setCellStyle ( cellStyleD ) ; cell = row . createCell ( col ++ ) ; cell . setCellValue ( text ) ; if ( cols >= 3 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_0 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 4 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_1 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 5 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_2 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 6 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_3 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 7 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_4 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 8 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_5 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 9 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_6 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 10 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_7 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 11 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_8 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 12 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_9 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 13 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_10 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 14 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_11 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 15 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_12 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 16 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_13 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 17 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_14 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 18 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_15 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 19 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_16 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 20 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_17 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 21 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_18 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 22 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_19 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } if ( cols >= 23 ) { text = new HSSFRichTextString ( formatValue ( rpt . getCol_20 ( ) ) ) ; cell = row . createCell ( col ++ ) ; cell . setCellStyle ( cellStyle ) ; cell . setCellValue ( text ) ; } }
pone la linea de informacion en el xls put information line into xls
