Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

St3.03 StShellNotification

10 views
Skip to first unread message

Ralph Sickinger

unread,
Dec 10, 2002, 3:48:36 PM12/10/02
to
Using St3.03, Delphi 5, Win2k Pro:

Setting the watchfolder to point at a specific folder, then copying files
into that folder; the only event that fires is OnFileChange, and when I look
at the shellItem property, it contains my *folder*, and not the new file.

Any advice? I need to know specifically when new files "appear" in my
watched folder.

TIA,
Ralph S.


Stephen Posey [TurboPower Software]

unread,
Dec 11, 2002, 1:18:39 PM12/11/02
to

I'm actually surprized you get OnFileChange; AFAIK, adding a
group of files will only fire OnFolderChange. What event are you
expecting?

Stephen Posey [TurboPower Software]
--
Please respond to the newsgroups and not via email.
This way, everyone benefits from knowing what was said.
Replies to mails...@turbopower.com will be copied back
to the newsgroup.


Ralph Sickinger

unread,
Dec 11, 2002, 1:43:17 PM12/11/02
to
I'm sorry, I believe that you are correct, I am getting "onFolderChange"; I
was kinda hoping for "onFileCreate" as each file is added to the folder.
(Or would that be too logical for M$?)

What action *does* cause "onFileCreate" to be invoked? Is there any point
to having options for a dozen different triggers, if the only one that ever
gets called is "onFolderChange"?

Thanks,
Ralph S.

"Stephen Posey [TurboPower Software]" <step...@turbopower.com> wrote in
message news:3DF7817F...@turbopower.com...

Stephen Posey [TurboPower Software]

unread,
Dec 11, 2002, 1:50:39 PM12/11/02
to
Ralph Sickinger wrote:
> I'm sorry, I believe that you are correct, I am getting "onFolderChange"; I
> was kinda hoping for "onFileCreate" as each file is added to the folder.
> (Or would that be too logical for M$?)
>
> What action *does* cause "onFileCreate" to be invoked? Is there any point
> to having options for a dozen different triggers, if the only one that ever
> gets called is "onFolderChange"?

That's one of the dirty little secrets of Shell notifications.

File creation (and a few of the other file specific
notifications) is generally only triggered if the application
operating on the file explicitly notifies the Shell that it's
done so (via the SHChangeNotify API).

Few applications bother to do this, including some that you'd
think would know better (e.g. Microsoft Word, and even Notepad).

Barring that you'll generally only get OnFileCreate when a new
file is created using the "New" menu in Explorer.

0 new messages