launching on Wintel/inter-process communication

Ken Ray kray at sonsothunder.com
Tue Dec 3 15:52:01 EST 2002


> I've avoided this technique simply because I've never been able to figure
> how to account for a crashed process and a leftover file.  If your app
> crashes (rare, I know) and your temporary file is still present, how do
you
> distinguish between "current" file versus a leftover?

Simple. Write the milliseconds into the file. Then, when the app launches,
grab the milliseconds as its "launch date". When it goes to look in the
folder, it will read in the "leftover" file, but because the milliseconds in
the leftover is *earlier* than the launch date, it is ignored. It will only
read files written into the "watched" folder *after* the launch date.

Ken Ray
Sons of Thunder Software
Email: kray at sonsothunder.com
Web Site: http://www.sonsothunder.com/




More information about the metacard mailing list