Re: Timestamp monitoring

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance




"Flo" <florian.puthod@xxxxxxxxx> wrote in message
news:1173877999.851516.77120@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
On Mar 14, 2:17 am, "Pegasus \(MVP\)" <I...@xxxxxxx> wrote:
<florian.put...@xxxxxxxxx> wrote in message

news:1173811870.628446.278880@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

Are the file names the same or are they unique?

Files would have different names and unique (as randomly generated by
the fax server - but it is not timestamp)
on a simple side I was thinking of list the directory where those
files are stored in order to be processed with a dir /tw then somehow
check the timestamp of the last file and do something is one file has
been sitting here for more than let's say 20 minutes.



You could use the Task Scheduler to run the batch file below
once every 20 minutes. It will delete every file that existed
20 minutes ago.

@echo off
if not exist c:\dir.txt goto :Label1
for /F %%a in (c:\dir.txt) do if exist "%%a" echo del "%%a"

:Label1
dir /b "c:\fax\*.txt" > c:\dir.txt

Remove the word "echo" in Line 3 to activate the batch file.


.



Relevant Pages

  • Re: Persisting env vars in cmd windows
    ... The help text for the command you question goes like this: ... format by typing this: echo %date% ... If you don't then the batch file will fail. ... echo:: ERROR ERROR ERROR ERROR ...
    (microsoft.public.win2000.general)
  • Re: Win2000 Printing Nightmare
    ... Purge the print spooler, to do so at a command prompt issue the ... You can make a small batch file to do the above job, ... @echo off ... ping localhost -n 4> nul ...
    (microsoft.public.win2000.file_system)
  • Re: logging batch files
    ... @echo off ... REM the start of your batch file ... >set LogCmd= ... >:LogIt ...
    (microsoft.public.win2000.cmdprompt.admin)
  • Re: Batch File Parameters
    ... While your batch file uses a number of advanced features, ... > @echo off ... > goto GETNEXT ... > a folder in "My Documents" and move them to an Archive folder while ...
    (microsoft.public.windowsxp.general)
  • Re: Disk Free Space Alert
    ... If you want a percentage then you can run this batch file: ... $goto Start ... $ echo Press the Space Bar to close this window. ... $echo Free space on drive %Drive% is %percent%%% of capacity ...
    (microsoft.public.win2000.general)