1
如何检查的日期是在VB就像两个给定日期之间:如何检查是否一个日期是两个给定日期之间
If (BirthDate Between T1 and T2) Then
Label5.Caption = " Your Horoscope Sign is LIBRA"
End If
如何检查的日期是在VB就像两个给定日期之间:如何检查是否一个日期是两个给定日期之间
If (BirthDate Between T1 and T2) Then
Label5.Caption = " Your Horoscope Sign is LIBRA"
End If
你需要将它T1和T2之间的比较。像这样的东西应该工作。请记住,年份必须相同或比较不起作用,如果您不希望删除等号,则此比较包括端点,这也假设您正在使用日期对象
If (BirthDate >= T1 And BirthDate <= T2) Then
Label5.Caption = "You're In"
Else
Label5.Caption = "You're Out"
End If
If (BirthDate >= T1 And BirthDate <= T2) Then
Label5.Caption = "You're In"
Else
Label5.Caption = "You're Out"
End If