国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 網站 > 建站經驗 > 正文

asp 格式化-時間日期

2019-11-02 15:47:57
字體:
來源:轉載
供稿:網友

  asp教程 格式化時間日期

  public function formatdt(dt, style)

  'style=0 2000-10-10 下午 12:17:45

  'style=1 2000-10-10 23:17:45

  'style=2 2000-10-10 23:45

  'style=3 00-10-10 23:45

  'style=4 10-10 23:45

  'style=5 2000-10-10

  'style=6 00-10-10

  'style=7 10-10

  'style=8 23h-45m-45s

  'style=9 20001010231745

  'style=10 0510   上傳圖片

  'style=11 05年10月10日

  'style=12 05/10/12   上傳圖片

  dim nowdate, y, m, d, h, i, s, t, apm, hapm

  nowdate = dt

  y = year(nowdate)

  if len(y)=1 then y="0"&y

  m = month(nowdate)

  if len(m)=1 then m="0"&m

  d = day(nowdate)

  if len(d)=1 then d="0"&d

  h = hour(nowdate)

  if len(h)=1 then h="0"&h

  i = minute(nowdate)

  if len(i)=1 then i="0"&i

  s = second(nowdate)

  if len(s)=1 then s="0"&s

  if h > 12 then

  apm = "下午 "

  hapm = cstr(cint(h) mod 12)

  else

  apm = "上午 "

  hapm = h

  end if

  select case style

  case 0

  t = y & "-" & m & &

爆笑圖片大全[www.62-6.com/1/baoxiaotupian]
quot;-" & d & " " & apm & hapm & ":" & i & ":" & s

  case 1

  t = y & "-" & m & "-" & d & " " & h & ":" & i & ":" & s

  case 2

  t = y & "-" & m & "-" & d & " " & h & ":" & i

  case 3

  t = right(y, 2) & "-" & m & "-" & d & " " & h & ":" & i

  case 4

  t = m & "-" & d & " " & h & ":" & i

  case 5

  t = y & "-" & m & "-" & d

  case 6

  t = right(y, 2) & "-" & m & "-" & d

  case 7

  t = m & "-" & d

  case 8

  t = h & "h-" & i & "m-" & s &"s"

  case 9

  t = y & m & d & h & i & s

  case 10'上傳

  t = right(y, 2) & m

  case 11

  t = right(y, 2) & "年" & m & "月" & d & "日"

  case 12

  t = right(y, 2) & "/" & m & "/" & d

  end select

  formatdt = t

  end function

發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 闵行区| 古交市| 西充县| 中阳县| 保山市| 信阳市| 姜堰市| 平阴县| 万载县| 安塞县| 南昌县| 靖安县| 广丰县| 普兰县| 湾仔区| 定日县| 胶南市| 浠水县| 沅江市| 泸定县| 黔江区| 九江市| 津市市| 平昌县| 进贤县| 卓尼县| 保定市| 廊坊市| 普兰店市| 赣州市| 磐石市| 永州市| 莫力| 全椒县| 三都| 勐海县| 盐源县| 彩票| 陈巴尔虎旗| 阳新县| 商洛市|