2个回答
2013-12-16
展开全部
Option Base 1
Dim t1, t2, b As String
Private Sub Form_Load()
Dim x(3)
b = InputBox("请输入事件内容", "提示")
For i = 1 To 3
If i = 1 Then a = "年"
If i = 2 Then a = "月"
If i = 3 Then a = "日"
x(i) = InputBox("请输入" & b & "准确" & a, "提示")
Next i
t1 = DateSerial(x(1), x(2), x(3))
Timer1.Enabled = True
Timer1.Interval = 1000
End SubPrivate Sub Timer1_Timer()
Label1.Caption = "距离" & b & "还有 " & DateDiff("d", Date, t1) & "天"
End Sub看下是不是这样 的
Dim t1, t2, b As String
Private Sub Form_Load()
Dim x(3)
b = InputBox("请输入事件内容", "提示")
For i = 1 To 3
If i = 1 Then a = "年"
If i = 2 Then a = "月"
If i = 3 Then a = "日"
x(i) = InputBox("请输入" & b & "准确" & a, "提示")
Next i
t1 = DateSerial(x(1), x(2), x(3))
Timer1.Enabled = True
Timer1.Interval = 1000
End SubPrivate Sub Timer1_Timer()
Label1.Caption = "距离" & b & "还有 " & DateDiff("d", Date, t1) & "天"
End Sub看下是不是这样 的
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
2013-12-16
展开全部
Private Sub Form_Load()
Timer1.Enabled = True
Timer1.Interval = 10000
End Sub
Private Sub Timer1_Timer()
Label1.Caption = "距离XXXXXXX还有" & DateDiff("d", Date, #12/10/2012#) & "天"
End Sub
完全符合你的意见。
Timer1.Enabled = True
Timer1.Interval = 10000
End Sub
Private Sub Timer1_Timer()
Label1.Caption = "距离XXXXXXX还有" & DateDiff("d", Date, #12/10/2012#) & "天"
End Sub
完全符合你的意见。
本回答被网友采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询