New Template, EmbedFileNotifyFunctions

The purpose of this template is to make available in the procedure to which it is attached, a new class called HNDFileNotify. This is a very small, but powerful class which gives your procedure the ability to notify your application via EVENT:FileChanged whenever a new file is added to a nominated directory or a file in the nominated directory is changed in any way.
There are hundreds of uses for this small but powerful feature, from backup applications to autoupload and cross-posting capability. I've provided a small application to illustrate one use.
Example Application Using EmbedFileNotifyFunctions
This application illustrates a new CHT template called EmbedFileNotifyFunctions and a new class called HNDFileNotify(HNDFILENOTIFY.INC/HNDFILENOTIFY.CLW).

The class attached to your procedure by this template, once initialized gives your procedure the ability to detect all changes occuring in a nominated directory. Whenever a new file is added to this directory, or a file is changed, your procedure is sent an event called EVENT:FileChanged to signal that this has occurred. At that point, what you do as a programmer to act on that event is wide open.
This application illustrates one use of this new, directory monitoring capability. When a file is added to the designated source directory, that file is copied into a temporary, processing directory, from where it is compressed and encrypted into a CHT .HZO transport container.
The file or files meeting the filter setting provided on the application interface, eventually then, end up compressed into this .HZO container. There is also an optional switch to remove the processed source file(s) from the directory being
monitored.
Cheers...
Gus Creces
The Clarion Handy Tools Page
www.cwhandy.com
support@cwhandy.com
August 14, 2009