Bonjour,
Voila le script d'info sur les drives :
► Afficher le texte
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#NoTrayIcon
$NomMonLecteurUSB = "XXX"
$var = DriveGetDrive( "all" )
global $source
global $position
$position=1
If NOT @error Then
For $i = 1 to $var[0]
_testmonlecteur()
$position=$position+1
Next
EndIf
Func _testmonlecteur()
$Lecteur = $var[$i]
$nom = StringLower(DriveGetLabel( $Lecteur ))
$type = StringLower(DriveGetType( $Lecteur ))
if $nom = $NomMonLecteurUSB Then
$source=$var[$i]
msgbox ("","Identification de mon lecteur","C'est mon disque " & @CRLF & @CRLF & "Position --> " & $position & @CRLF & "Lettre --> " &$lecteur & @CRLF & "Label --> " & $nom & @CRLF & "Autre--> " & $type)
Else
msgbox ("","Identification de mon lecteur","Ce n'est pas mon disque " & @CRLF & @CRLF & "Position --> " & $position & @CRLF & "Lettre --> " &$lecteur & @CRLF & "Label --> " & $nom & @CRLF & "Autre--> " & $type)
EndIf
EndFunc
Il recherche bien tous les drives, mais n'affiche pas la vrais positon du lecteur si il y a 1 ou 2 partition sur un HDD. Et je n'ai pas trouver le mot clef pour l'afficher.
Merci pour l'aide.