For get the serial number of all hard drives in my computer, I use:
wmic diskdrive get serialnumber
But, I want to get the serial number of the hard drive where I am working.
I explain:
I have 2 hard drives, one of them has 2 partitions C and D. The other has one partition E. With the command line, if I am working in C partition, when I type the wmic command, I want to get only the serial number of the hard drive which has this partition, not the serial of the hard drive with the E partition.
I want to make a license code for my software. you can install the software in any partition. i want the serial number of the hard drive that contains these partition specifycally. the volume serial number of the partition changes when you format, reinstall, etc, but the serial number of the hard drive not. i know there are softwares to change the serial number, but my possible clients are not so smarts.