Google Sheet API V4(Java) append Date in cells

To provide an example of what Sam’s answer means, if you just want to create a date value using AppendCellsRequest, you can create the cell like this:

CellData cell = new CellData();
cell.setUserEnteredValue(new ExtendedValue().setNumberValue(42198.0));
cell.setUserEnteredFormat(
    new CellFormat().setNumberFormat(new NumberFormat().setType("DATE")));    

Here 42198 is the number of days between December 30th 1899 and July 13th 2015.

Leave a Comment