VB6或者ASP 格式化时间为 MM/dd/yyyy 格式,竟然没有好的办法,
Format 或者FormatDateTime 竟然结果和系统设置的区域语言的日期和时间格式相关。意思是尽管你用诸如 Format(Now,"MM/dd/yyyy"),如果系统的设置格式区域语言的日期和时间格式分隔符是"-",那他还会显示为 MM-dd-yyyy
只有拼凑:
<%response.write testDateFormatFunction testDateFormat() Dim gMeetStartDate,gMeetEndDateDim sMeetStartDate,sMeetEndDategMeetStartDate = NowgMeetEndDate = DateAdd("m",24,gMeetStartDate)sMeetStartDate = right("00"& Month(gMeetStartDate),2) & "/" & right("00"& Day(gMeetStartDate),2) & "/" &right("0000"& Year(gMeetStartDate),4)sMeetEndDate = right("00"& Month(gMeetEndDate),2) & "/" & right("00"& Day(gMeetEndDate),2) & "/" & right("0000"& Year(gMeetEndDate),4)testDateFormat = sMeetStartDate & "," & sMeetEndDateEnd Function%>