Hi Rohit,
Well, it 's working. I tested it.
Following is my sample code using your template file and attached is the screen shot of the output value.
import java.io.*;
import com.aspose.cells.*;
class DateVal1
{
public static void main(String []args)
{
try
{
Workbook workbook = new Workbook();
workbook.open("e:\\Files\\TEST_FILE.xls");
workbook.calculateFormula();
Worksheet worksheet = workbook.getWorksheets().getSheet(0);
Cells cells = worksheet.getCells();
Cell cell = cells.getCell("A22");
cell.setFormula("=DATEVALUE(H12)");
workbook.calculateFormula();
System.out.println(cell.getValue());
}
catch(Exception ee)
{
System.out.println(ee);
}
}
}
Please make sure that you are using the latest hotfix which Warren posted you.
Thank you.
Amjad Sahi
Support Developer,
Aspose Sialkot Team
Contact Us