Getting the HD serial number [OT]
Hiya,
I'm not sure if I should be posting this message here, but here we go:
How can I extract the serial number of the HD from which my program is running? Some friends of mine have done it using Assembly, but I'd like to do it using C++.
Thanks in advance!
Edited by - HellRaider on 6/22/00 8:08:23 PM
Hi!
Here is the small piece of code to get the HDD s/n
DWORD dwSerial = 0;
GetVolumeInformation("C:\\",NULL,0,&dwSerial,NULL,NULL,NULL,0);
The HDD s/n is stored in dwSerial, of course
I hope it will help you
BugKiller
www.bugkiller.net
Here is the small piece of code to get the HDD s/n
DWORD dwSerial = 0;
GetVolumeInformation("C:\\",NULL,0,&dwSerial,NULL,NULL,NULL,0);
The HDD s/n is stored in dwSerial, of course
I hope it will help you
BugKiller
www.bugkiller.net
BugKillerwww.bugkiller.net
That works of course, if you want the sissy way out
-----------------------------
A wise man once said "A person with half a clue is more dangerous than a person with or without one."
-----------------------------
A wise man once said "A person with half a clue is more dangerous than a person with or without one."
-----------------------------A wise man once said "A person with half a clue is more dangerous than a person with or without one."The Micro$haft BSOD T-Shirt
Then, by all means, please enlighten all of us at GameDev and show us the "manly" way to retrieve the hard drive serial number.
Well, it was a light hearted joke, but the manly way would be to go low level and do all thw work yourself.
-----------------------------
A wise man once said "A person with half a clue is more dangerous than a person with or without one."
-----------------------------
A wise man once said "A person with half a clue is more dangerous than a person with or without one."
-----------------------------A wise man once said "A person with half a clue is more dangerous than a person with or without one."The Micro$haft BSOD T-Shirt
June 23, 2000 11:41 PM
Well, are you manly or not?!? Show us all how right now to prove your manhood...
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement