📜  比较日期 vb - VBA 代码示例

📅  最后修改于: 2022-03-11 14:51:54.362000             🧑  作者: Mango

代码示例1
Dim result As Integer = DateTime.Compare(date1, date2)
      
      If result < 0 Then
        'date1 is earlier than date2
      ElseIf result > 0 Then
         'date1 is later than date2        
      ElseIf result = 0 Then
          'date1 is the same as date2
      End If