Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
Widgetset
»
Cocoa
»
How to monitor a folder for changes
Free Pascal
Website
Downloads
Wiki
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Bugtracker
IRC channel
Latest SVN
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
Recent
TLineSeries display every...
by
wp
[
Today
at 12:35:34 pm]
Copy File to MTP
by
dbannon
[
Today
at 12:31:09 pm]
Anyone using Fast-Reports...
by
Thaddy
[
Today
at 12:04:32 pm]
S.M.A.R.T.: How to read?
by
JernejL
[
Today
at 10:54:37 am]
doc (CHM) snapshot update...
by
Andrey Sobol
[
Today
at 10:26:09 am]
Streaming video to a web ...
by
BlueIcaro
[
Today
at 10:19:16 am]
ANN: TRichView 19 (rich t...
by
Sergey Tkachenko
[
Today
at 09:52:16 am]
Batch layer export
by
MarkMLl
[
Today
at 09:47:41 am]
QT 6?
by
marcov
[
Today
at 09:43:46 am]
TImagelist load at run ti...
by
torbente
[
Today
at 07:09:38 am]
« previous
next »
Print
Pages: [
1
]
Author
Topic: How to monitor a folder for changes (Read 477 times)
Igor Kokarev
Sr. Member
Posts: 303
How to monitor a folder for changes
«
on:
October 22, 2020, 02:52:34 pm »
Hi,
How to monitor a folder for changes (new/modified files/folders) with Cocoa in macOS? Is there any examples on FPC?
Logged
MarkMLl
Hero Member
Posts: 1740
Re: How to monitor a folder for changes
«
Reply #1 on:
October 22, 2020, 02:57:52 pm »
I've done it on linux but I don't know whether the same API is applicable to Macs.
MarkMLl
Logged
Turbo Pascal v1 on CCP/M-86, multitasking with LAN and graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.
trev
Global Moderator
Hero Member
Posts: 1193
Former Delphi 1-7, 10.2 User
Re: How to monitor a folder for changes
«
Reply #2 on:
October 23, 2020, 01:48:52 am »
See
File System Events
and packages/univint/src/FSEvents.pas
Logged
o Lazarus 2.1.0 r64368, FPC 3.3.1 r48100, macOS 10.14.6, Xcode 11.3.1
o Lazarus 2.1.0 r64392, FPC 3.3.1 Jan 13 21:24, macOS 11.1 (aarch64), Xcode 12.3
o Lazarus 2.1.0 r61574, FPC 3.3.1 r42318, FreeBSD 12.1 amd64 (VMware VM)
o Lazarus 2.1.0 r61574, FPC 3.0.4, Ubuntu 20.04 (Parallels VM)
Igor Kokarev
Sr. Member
Posts: 303
Re: How to monitor a folder for changes
«
Reply #3 on:
October 23, 2020, 01:37:13 pm »
trev,
Mark,
Many thanks for your replies!
I'll learn FSEvents now.
Logged
Alextp
Hero Member
Posts: 1167
Re: How to monitor a folder for changes
«
Reply #4 on:
October 23, 2020, 02:01:45 pm »
DirectoryWatcher
https://forum.lazarus.freepascal.org/index.php/topic,37415.0.html
Logged
CudaText editor
-
ATSynEdit
-
More from me
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
Widgetset
»
Cocoa
»
How to monitor a folder for changes
TinyPortal
© 2005-2018