春 春天小雨 Unregistered / Unconfirmed GUEST, unregistred user! 2000-09-08 #1 是不是发一条WM_devicechang消息,告之详细情况!!!!
H Haha... Unregistered / Unconfirmed GUEST, unregistred user! 2000-09-09 #2 学别人的,试试吧 public procedure WMDeviceChange(var Msg: TMsg); message WM_DEVICECHANGE; implementation procedure TForm1.WMDeviceChange(var Msg: TMsg); begin if Msg.wParam = DBT_DEVICEREMOVEPENDING then // 用户已弹出CD Msg.Result := True; end;
学别人的,试试吧 public procedure WMDeviceChange(var Msg: TMsg); message WM_DEVICECHANGE; implementation procedure TForm1.WMDeviceChange(var Msg: TMsg); begin if Msg.wParam = DBT_DEVICEREMOVEPENDING then // 用户已弹出CD Msg.Result := True; end;