VERSION 5.00
Begin VB.Form Form1 
   Caption         =   "Format函数"
   ClientHeight    =   1635
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   3285
   LinkTopic       =   "Form1"
   ScaleHeight     =   1635
   ScaleWidth      =   3285
   StartUpPosition =   3  '窗口缺省
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False

Private Sub Form_Click()
      FontSize = 12
      MyTime = #9:21:30 PM#
      MyDate = #7/21/1997#
      Print Tab(2); Format(MyDate, "m/d/yy")
      Print Tab(2); Format(MyDate, "mmmm-yy")
      Print Tab(2); Format(MyTime, "h-m-s AM/PM")
      Print Tab(2); Format(MyTime, "hh:mm:ss A/P")
      Print Tab(2); Format(Date, "dddd,mmmm,dd,yyyy")   ' 显示系统当前日期
      Print Tab(2); Format(Now, "yyyy年m月dd日 hh：mm") ' 显示系统当前日期和时间
      Print FormatDateTime(Now)                         ' vb6.0新提供的函数
End Sub

