0
有沒有辦法解析dateBox()中的時間,或者更好但是一起消除它?我希望有人能夠使用dateBox()僅選擇日期,但希望擺脫時間並使用我創建的另一個函數。在dateBox()中解析時間,或消除日期框中的時間
感謝
有沒有辦法解析dateBox()中的時間,或者更好但是一起消除它?我希望有人能夠使用dateBox()僅選擇日期,但希望擺脫時間並使用我創建的另一個函數。在dateBox()中解析時間,或消除日期框中的時間
感謝
這樣做的一個簡單的方法是這樣的:
var date = new Date(e.parameter.start);// convert the string to a full date object (with time value) (the date widget is named 'start' in this example)
var dateOnly = date.setHours(0,0,0,0); // set time to '0' (hours,min,sec,millisec)or use the hours and minutes you get from elsewhere...
,我用這個數據從2列(日期和時間)創建相結合,您可以看看this example sheet一個完整的日期對象