Joe,
thanks... looks like that should work for me.
Chris
"Joseph Youngquist"
<[EMAIL PROTECTED]> To:
Sent by:
<[EMAIL PROTECTED]>,
[EMAIL PROTECTED]
<[EMAIL PROTECTED]>
eState.com cc:
Subject: Re:
win32::changenotify problem
01/24/2001 08:09 AM
Take a "snap shot" of the directory:
use DirHandle;
$Incoming = new DirHandle "$IncomingDir'g";
@DirStructure = $Incoming->read;
undef $Incoming;
Now @DirStructure has an "image" of the incoming Dir. When you unzip, take
another snap shot and work on the file that does not match.
That's if the unziped file is staying in the same folder. If not, use
the change-notify on the new directory where you saved the unziped file.
(shift the @DirStructure twice to remove the currnent Dir and Up Dir
thingies i.e. [ . ] [ .. ] )
Hope that this helps.
Joe.
----- Original Message -----
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, January 23, 2001 5:52 PM
Subject: win32::changenotify problem
> Hi,
>
> I'm attempting to use win32::changenotify to monitor a directory for new
> files that get added. I'm creating a change notify object with the
> FILE_NOTIFY_CHANGE_SIZE flag. When a new file is detected, I want to
unzip
> it with gzip, pull stuff out of it, and then delete it. Its not doing
quite
> what I want it to.
>
> I think the problem I am running into is that when a new file is added to
> the monitored directory and it gets unzipped, its name changes, as well
as
> its size. So my script incorrectly detects this unzipped file as a newly
> added one, and tries to repeat those processing steps on it as the next
> 'new' file.
>
> Can anyone suggest another way of making this happen, other than moving
the
> zipped file to a non-monitored directory, and processing it there?
>
> Thanks for any input.
>
>
>
>
>
> _______________________________________________
> Perl-Win32-Admin mailing list
> [EMAIL PROTECTED]
> http://listserv.ActiveState.com/mailman/listinfo/perl-win32-admin
>
_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-admin
_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-admin