Hi all,
I have written the following code to open up a word document and then save it with a time stamp. This works fine. ( Path and File are variants storing the Path and file name of the document)
Set wrd = CreateObject("Word.Application"
Set docBomb = wrd.Documents.Open(Path & File & ".DOC"
wrd.Visible = True
'Get Date and Time for File Name
currentDateTime = Now
TimeStamp = Format(currentDateTime, "dd-mm-yyyy h-nn-ss"
docBomb.SaveAs (Path & File & TimeStamp & ".DOC"
What I want to do now is continue saving this document every 10 seconds until the user closes the document.
Does anybody know how to test to see if the word document is open or closed? Then I can write a Do Until loop, until the user closes the document.
Regards
Dongal
I have written the following code to open up a word document and then save it with a time stamp. This works fine. ( Path and File are variants storing the Path and file name of the document)
Set wrd = CreateObject("Word.Application"
Set docBomb = wrd.Documents.Open(Path & File & ".DOC"
wrd.Visible = True
'Get Date and Time for File Name
currentDateTime = Now
TimeStamp = Format(currentDateTime, "dd-mm-yyyy h-nn-ss"
docBomb.SaveAs (Path & File & TimeStamp & ".DOC"
What I want to do now is continue saving this document every 10 seconds until the user closes the document.
Does anybody know how to test to see if the word document is open or closed? Then I can write a Do Until loop, until the user closes the document.
Regards
Dongal