dim szDate as string dim szYear as string, szMonth as string, szDay as stringszDate=format("YYYY年MM月DD日 HH点NN分SS秒",now)szYear=year(now) szMonth=month(now) szDay=day(now)
Type SYSTEMTIME ' 16 Bytes wYear As Integer wMonth As Integer wDayOfWeek As Integer wDay As Integer wHour As Integer wMinute As Integer wSecond As Integer wMilliseconds As IntegerEnd TypePublic Declare Sub GetSystemTime Lib "kernel32" (lpSystemTime As SYSTEMTIME)Public Function GetDay() As String Dim T As SYSTEMTIME
MyDay = Day(Date)
MyMonth = Month(Date)
strdate=year(date) & "年" & month(date) & "月" & day(date) & "日"
msgbox strdate
Day(Date)
Month(Date)
msgbox str
msgbox date
dim szYear as string, szMonth as string, szDay as stringszDate=format("YYYY年MM月DD日 HH点NN分SS秒",now)szYear=year(now)
szMonth=month(now)
szDay=day(now)
wMonth As Integer
wDayOfWeek As Integer
wDay As Integer
wHour As Integer
wMinute As Integer
wSecond As Integer
wMilliseconds As IntegerEnd TypePublic Declare Sub GetSystemTime Lib "kernel32" (lpSystemTime As SYSTEMTIME)Public Function GetDay() As String Dim T As SYSTEMTIME
Call GetSystemTime(T)
GetDay = T.wYear & "年" & T.wMonth & "月" & T.wDay & "日"End Function
就可以吧!年月日时间都有了
嘿嘿,很省事