1
다음 코드를 사용하여 30 초마다 실행 한 후 9 분 동안 실행해야 계속 이동합니다. 어떤 아이디어?Visual Basic에서 매 30 초마다 실행되는 시간 지정 루프 만들기
'Begin 9 minute loop
CLEAR CONTENTS
Dim newFIle
Set FSO = CreateObject("Scripting.FileSystemObject")
Set newFIle = FSO.CreateTextFile("C:\Users\Owner\Desktop\RECALL\OutlookExport.csv", True, False)
newFIle.Write "Need Data"
newFIle.Close
Set FSO = CreateObject("Scripting.FileSystemObject")
'Choose File
Set csvOut = FSO.OpenTextFile("C:\Users\Owner\Desktop\RECALL\OutlookExport.csv", 8, True)
'Export Messages
For Each email In inbox.Folders.Item(CInt(response)).Items
csvOut.Write (Chr(34) & email.SenderName & Chr(34) & ",")
csvOut.Write email.Body
csvOut.Write (vbNewLine)
Next
'Pause 30 seconds
'Return to "Begin 9 Minute Loop
'Repeat 18 times
'End 9 minute loop (Execute remainder of code)