require("topsin.excelxs");
try {
    var book = new Book;
    var ok = book.create("test.xlsx");
    if (!ok) throw "open xlsx failed.";
    var sheet = book.addSheet("test");
    var font = book.addFont();
    font.setColor("#FF0000");
    var format = book.addFormat();
    format.setFont(font);
    sheet.setCellValue(0, 0, "DIRTY");
    sheet.setCellFormat(0, 0, format);
    book.save();
    book.close();
} catch(e) {
    print(e);
}