Basically it just uses the WM_DEVICECHANGE notifictation I then
check if (Msg.WParam = DBT_DEVICEARRIVAL) or (Msg.WParam =
DBT_DEVICEREMOVECOMPLETE
if either is true then
   devType  : Integer;
   Datos    : PDevBroadcastHdr;
      Datos := PDevBroadCastHdr(Msg.LParam);
      devType := Datos^.dbch_devicetype;
if devType = DBT_DEVTYP_DEVICEINTERFACE then USB device has been
added / removed


--- In [email protected], "wizzszz" <[EMAIL PROTECTED]> wrote:
>
> Could you post the USB notification code, or a link where to get
it?
> Or does it simply use WM_DEVICECHANGE?
>
> TIA, wizzszz
>   ----- Original Message -----
>   From: texman_uk
>   To: [email protected]
>   Sent: Thursday, May 11, 2006 6:04 PM
>   Subject: [delphi-en] Detect Insertion / removal of CF cards
>
>
>   I am trying to detect when a cf card (or similar) is inserted
into a
>   drive, I have got some code that detects the insertion / removal
of a
>   usb device and from here i can detect whether it is of type
volume and
>   whether or not a disk is present, however if i attach a usb card
>   reader with no card and then insert a card at a later date i
can't
>   detect this occurring - I am currently monitoring the
WM_DEVICECHANGE
>   message but do not get a notification when a card is inserted /
>   removed, does anyone know what message i need to monitor or how
i can
>   get notification when the card is inserted / removed
>
>   cheers
>
>
>
>
>
>
>   -----------------------------------------------------
>   Home page: http://groups.yahoo.com/group/delphi-en/
>   To unsubscribe: [EMAIL PROTECTED]
>
>
>
>   SPONSORED LINKS C programming language  Computer programming
languages  Java programming language 
>         The c programming language  C programming language 
Concept of programming language 
>
>
> -------------------------------------------------------------------
-----------
>   YAHOO! GROUPS LINKS
>
>     a..  Visit your group "delphi-en" on the web.
>      
>     b..  To unsubscribe from this group, send an email to:
>      [EMAIL PROTECTED]
>      
>     c..  Your use of Yahoo! Groups is subject to the Yahoo! Terms
of Service.
>
>
> -------------------------------------------------------------------
-----------
>
>
>
> [Non-text portions of this message have been removed]
>






-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED]




SPONSORED LINKS
C programming language Computer programming languages Java programming language
The c programming language C programming language Concept of programming language


YAHOO! GROUPS LINKS




Reply via email to