Normally when we disconnect a USB flash drive, we have to right-click the lower right corner of the taskbar and remove hardware. Is there a way to do it with DOS commands instead?
Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!
@echo off
for /f %%i in ('devcon findall usb* ^|find /i "usb mass storage"') do devcon remove "@%%i"
devcon rescan