Merci pour la réponse KarCAroun, ça marche bien ton truc. Sous diskpart, j'ai tapé "list vol" et c'est exactement ce que je cherchais qui est apparu. Coup de chapeau KarAroun ! Voilà à présent j'ai un nouveau problème : quand je connecte un nouveau périphérique de stockage, j'ai le nom du lecteur correspondant qui apparaît aussi. Comment le capturer dans une variable d'environnement et l'utiliser dans mon batch ? J'ai pensé à "|" et au "for". Merci.
fsutil fsinfo drives
There are indeed many old computers with MS-DOS, just answer the question sometimes!
You can try fdisk
!!! Be careful not to format everything
What are you running, Win 95-98???
Hello,
Since this is about politely responding to off-topic posts, we should first agree on what old computers are.
Real DOS mode is only supported up to Windows 98; after that, we have a 32-bit command interpreter.
Even if the ancient machine runs under MsDos 6.22 without Shell or Windows 3.11 where the FOR command is operational, FSUTIL only works in emulated DOS.
In the first case, we will indeed have issues with network drives unless a letter is assigned to them via SUBST, and they must also be accessible, meaning that specific network drivers need to be added to MsDos, along with USB drives.
Starting from Windows 95, the syntax is universal, as noted on Professor Salmi's Batch site, which struggles to even know XP as early as 2010-2011:
In emulated DOS, I can also get the type, and since it's in English, "No such Root Directory" needs to be replaced with "Ce répertoire racine n'existe pas"