Re: Ordner Überwachung
Verfasst: 06.08.2018 00:19
Hab den Code wieder gefunden und Fehler erkannt. Leider zu spät, da Projekt bereits ein paar Jahre auf Eis liegt
Gruß
Thomas
Code: Alles auswählen
Procedure FolderSpyLeft(*SLook.Look)
Protected exit, hchangeobject
While ThreadLeftStop = #False
hchangeobject = FindFirstChangeNotification_(*SLook\Directory, 0, #FILE_NOTIFY_CHANGE_FILE_NAME | #FILE_NOTIFY_CHANGE_DIR_NAME | #FILE_NOTIFY_CHANGE_LAST_WRITE | #FILE_NOTIFY_CHANGE_ATTRIBUTES)
If WaitForSingleObject_(hchangeobject, *SLook\milliseconds) = 0
ThreadLeftStop = #True
Continue
EndIf
FindNextChangeNotification_(hchangeobject)
Wend
EndProcedureThomas