Answer the question
In order to leave comments, you need to log in
Need to get information about a disk partition by file name?
Hello.
The general question is this - you need a windows log analyzer to audit file names in C#. In the log, the format for outputting messages about file operations looks like this:
Question: It is
required to get the file name in the format \Device\HarddiskVolumeNN (NN - section number)\path\to\file.ext by the full file name. The definition of the disk as "\Device\HarddiskVolume" is also quite satisfactory, and then I will replace the letter with replace.
PS
I found that it "seems" this can be done through WMI, but it seems to me that this is a long operation, at the same time the logging system itself does this without noticeable delays.
Answer the question
In order to leave comments, you need to log in
GetVolumeNameForVolume
QueryDosDevice
Also about you:
stackoverflow.com/questions/26573933/hard-disk-vol...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question