Problems with "Safely Remove Hardware"
From: Alex (alex130671_at_nexgo.de)
Date: Fri, 25 Jun 2004 15:12:35 +0200
I have a USB Mass Storage Device with some additional functionality. To get
functionality a server process is running and accessing to the USB Mass
Storage Device with
CreateFile(\\\\.\\PhysicalDriveX). I can read and write data to the USB Mass
while the server has opened the device also with CreateFile().
When I plugged out the device directly without using "Safely Remove
Hardware" no dialog
will occur. That is what I want ...
But when I use "Safely Remove Hardware" before I plugged out the USB Mass
and the server process is still running a message "The device "Removable
Device" cannot be
stopped right now. Try stopping the device agian later." is occured. Is
there are a possibility
to stop the device without getting this messages.
One possibilty could be that the server process gets a WM_... messages and
access to \\\\.\\PhysicalDriveX. But which message can do that?
don't do this.
All hints are welcome.