說明
CurrentDateTime 傳回報表目前的日期與時間。
動作
CurrentDateTime 傳回報表目前的日期與時間。日期與時間取自電腦的內部時鐘。
典型用法
只要想以目前的日期與時間印在報表上,就可以使用 CurrentDateTime。
範例
CurrentDateTime
如果在 1998 年 7 月 4 日的 4:45:18 開始列印報表,傳回 1998/07/04 4:45:18。
CurrentDateTime
如果在 1996 年 12 月 11 日的 17:14:33 開始列印報表,傳回 1996/12/11 17:14:33。
註解
日期與時間格式取決於 [國別設定] 控制台中的設定。
CurrentDateTime 產生的結果與下列公式相同:
CDateTime(CurrentDate, CurrentTime)