I am facing a problem while getting contents of cell using the JXL API, if I am using a formula in an Excel sheet.
Right now I am using the formula IF($L10="","",+ROUND($L10*1.375,3))
in each
cell, but when the cell value is blank I am getting junk characters when I call the cell.getContents()
method. The code snip is as follows.
Workbook = Workbook.getWorkbook(p_sourceFile);
excelsheet = workbook.getSheet(0);
...
for (int row = 1; row < noOfRows; row++)
{
cell = excelsheet.getCell(col, row);
content = cell.getContents();
System.out.println("content-" + content); -- Is giving me junk character? when the cell value is blank.
...