超級厲害的VBS定時提醒腳本 Remind.vbs
2020-07-26 11:56:34
供稿:網友
'/*=========================================================================
' * Intro 定時提醒,格式:時間|提示語,具體使用方法可以參考例子
' * FileName Remind.vbs
' * Author yongfa365
' * Version v1.0
' * WEB http://www.yongfa365.com
' * Email yongfa365[at]qq.com
' * FirstWrite http://www.yongfa365.com/Item/Remind.vbs.html
' * MadeTime 2008-06-18 19:26:32
' * LastModify 2008-06-18 19:26:32
' *==========================================================================*/
tx = True
used = ""
t = ""
'■■■■■■■■■■■■■■可修改區域開始■■■■■■■■■■■■■■
t = t & "|" & "10:00:00|hello,hi,是美女不!"
t = t & "|" & "11:30:00|美女,快吃飯了!"
t = t & "|" & "14:00:00|困不困?困了就休息會,注意關門,小心被偷窺哦,哇嘎嘎"
t = t & "|" & "16:30:00|想帥哥了吧,笑一笑^-^"
t = t & "|" & "17:30:00|好像要下班了哦。"
t = t & "|" & "18:00:00|帥哥還沒回家?快提醒下"
t = t & "|" & "22:30:00|哥哥,備份當前數據,時間要到了。"
'■■■■■■■■■■■■■■可修改區域結束■■■■■■■■■■■■■■
t = Right(t, Len(t) -1)
Do While tx
WScript.Sleep 10000'10秒種檢測一次
tixing()
Loop
Function tixing()
t2 = Split(t, "|")
For i = LBound(t2) To UBound(t2) step 2
txsj = CDate(Date & " " & t2(i))
If DateAdd("n", -1, Now) <= txsj And DateAdd("n", 1, Now) >= txsj And InStr(used, t2(i)) = 0 Then
'時間相差一分鐘且沒提醒過的的話提醒
MsgBox t2(i + 1)
used = used & t2(i)'提醒過的記錄一下
End If
Next
End Function