Total Commander Forum Index Total Commander
Форум поддержки пользователей Total Commander
Сайты: Все о Total Commander | Totalcmd.net | Ghisler.com | RU.TCKB
 
 RulesRules   SearchSearch   FAQFAQ   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Single Post  Topic: Консольная программа для смены буквы диска (флешки) 
Author Message
Tol!k



PostPosted: Tue Jun 26, 2012 23:03    Post subject: Reply with quote

Code:
@echo off &setlocal enableextensions

for /f "skip=1 delims=" %%i in ('wmic LogicalDisk where "DriveType=2" get Caption^,MediaType') do (
   for /f "delims=" %%j in ("%%i") do (for /f "tokens=1,2" %%i in ("%%j") do (
      if "%%j"=="" %ComSpec% /C "ReMount.exe" -ReMount %%i B: -f
      )
   ))
)

View user's profile Send private message


Powered by phpBB © 2001, 2005 phpBB Group