¿ù°£ Àα⠰Խù°

°Ô½Ã¹° 58°Ç
   
[powershell] next drive
±Û¾´ÀÌ : ÃÖ°í°ü¸®ÀÚ ³¯Â¥ : 2012-06-05 (È­) 15:19 Á¶È¸ : 3834
±ÛÁÖ¼Ò :
                          

http://itknowledgeexchange.techtarget.com/powershell/next-drive-letter/

function get-nextdriveletter {            

$disk = Get-WmiObject -Class Win32_LogicalDisk |
sort DeviceId -Descending |
select -First 1 -Property DeviceID            

$letter = ($disk.DeviceID).Substring(0,1).ToUpper()
if ($letter -eq "Z"){
 Write-Host "No more drive letters available"
}
else {
 $nextletter = [char](([byte][char]$letter) + 1)
 $nextletter
}            

}

À̸§ Æнº¿öµå
ºñ¹Ð±Û (üũÇÏ¸é ±Û¾´À̸¸ ³»¿ëÀ» È®ÀÎÇÒ ¼ö ÀÖ½À´Ï´Ù.)
¿ÞÂÊÀÇ ±ÛÀÚ¸¦ ÀÔ·ÂÇϼ¼¿ä.
   

 



 
»çÀÌÆ®¸í : ¸ðÁö¸®³× | ´ëÇ¥ : ÀÌ°æÇö | °³ÀÎÄ¿¹Â´ÏƼ : ·©Å°´åÄÄ ¿î¿µÃ¼Á¦(OS) | °æ±âµµ ¼º³²½Ã ºÐ´ç±¸ | ÀüÀÚ¿ìÆí : mojily°ñ¹ðÀÌchonnom.com Copyright ¨Ï www.chonnom.com www.kyunghyun.net www.mojily.net. All rights reserved.