📜  在应用程序脚本中显示时间 - 无论代码示例

📅  最后修改于: 2022-03-11 15:00:18.798000             🧑  作者: Mango

代码示例1
function myFunction() {
  var d = new Date();
  var timeStamp = d.getTime();  // Number of ms since Jan 1, 1970

  // OR:

  var currentTime = d.toLocaleTimeString(); // "12:35 PM", for instance
}