本帖最后由 jyswjjgdwtdtj 于 2023-10-22 14:42 编辑
- const docfilename="c:\1.doc"
- const wd=3 '星期几
- const t=8 '几点钟
- do
- if weekday(date)=(wd mod 7)+1 then
- do
- if hour(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
复制代码
|