本帖最后由 jyswjjgdwtdtj 于 2023-10-22 15:37 编辑
回复 12# FU586097 - const docfilename="c:\1.doc"
- const wd=3 '星期几
- const t=32 '第几分钟
- const h=19 '几点钟
- do
- if weekday(date)=(wd mod 7)+1 then
- do
- if hour(time)=h and minute(time)=t then
- print docfilename
- exit do
- end if
- wscript.sleep 60000
- loop
- end if
- wscript.sleep 60*60*24*1000
- loop
- sub print(docfilename)
- Dim wdApp, Doc
- Set wdApp = CreateObject("Word.Application")
- wdApp.Visible = False
- Set Doc = wdApp.Documents.Open(docfilename)
- Doc.PrintOut
- Doc.Close
- end sub
复制代码 你时间没到肯定不会执行啊
还有你干嘛改”日”啦! 你改成7就不行吗 |