Hello everybody,
I am trying to know USB mass storage was removed by safety or force as below
LRESULT CMainFrame::OnDeviceChange(WPARAM wParam, LPARAM lParam)
{
DEV_BROADCAST_HDR *pStructure;
switch(wParam)
{
case DBT_DEVICEARRIVAL:
break;
case DBT_DEVICEREMOVECOMPLETE:
pStructure = (DEV_BROADCAST_HDR *)lParam;
/////////////////////////////////////////
//I have to do .....//
/////////////////////////////////////////
break;
}
But I can't progress any more.
Any clue is heplful.
Please help me.
Thank you.
I am trying to know USB mass storage was removed by safety or force as below
LRESULT CMainFrame::OnDeviceChange(WPARAM wParam, LPARAM lParam)
{
DEV_BROADCAST_HDR *pStructure;
switch(wParam)
{
case DBT_DEVICEARRIVAL:
break;
case DBT_DEVICEREMOVECOMPLETE:
pStructure = (DEV_BROADCAST_HDR *)lParam;
/////////////////////////////////////////
//I have to do .....//
/////////////////////////////////////////
break;
}
But I can't progress any more.
Any clue is heplful.
Please help me.
Thank you.