Click here to Skip to main content
15,796,299 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionHow to get disk model and serial number for the disk Windows is installed on Pin
JohnCodding19-Sep-23 21:41
JohnCodding19-Sep-23 21:41 
AnswerRe: How to get disk model and serial number for the disk Windows is installed on Pin
Richard MacCutchan19-Sep-23 22:59
mveRichard MacCutchan19-Sep-23 22:59 
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
Valentinor19-Sep-23 23:15
Valentinor19-Sep-23 23:15 
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
Richard MacCutchan19-Sep-23 23:26
mveRichard MacCutchan19-Sep-23 23:26 
AnswerRe: How to get disk model and serial number for the disk Windows is installed on Pin
Richard MacCutchan19-Sep-23 23:28
mveRichard MacCutchan19-Sep-23 23:28 
AnswerRe: How to get disk model and serial number for the disk Windows is installed on Pin
JohnCodding19-Sep-23 23:57
JohnCodding19-Sep-23 23:57 
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
David Crow20-Sep-23 3:08
David Crow20-Sep-23 3:08 
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
trønderen20-Sep-23 11:34
trønderen20-Sep-23 11:34 
David Crow wrote:
diskdrive where DeviceID='\\\\.\\PHYSICALDRIVE0'produces a result that can be parsed.
In C/C++, each of those backslashes needs to be escaped (with a backslash).
The real problem is that people can say anything like that with at straight face: Sure, that which semantically '\\.\' is already escaped in one level, but certain conditions that are too difficult to explain means that every one of those six backslashes - semantically, they are only three - must be escaped to make the three of them into twelve escaped-escaped backslashes ..."

This is the kind of stuff that makes me sigh, "Sorry, workmates: We failed. This just doesn't work."

Even programmers have difficulties handling it (at least in counting the number of slashes when the debugger displays the string as \\\\\\\\.\\\\devicename). When we say 'OK with us!', the next step is that we expect non-IT users to accept something like that.

Really, it is like saying that 'In tttthis systtttem you have to repeatttt every tttt four ttttimes, because tttthatttt is tttthe way tttthe systtttem is builtttt!'
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
jschell20-Sep-23 14:13
jschell20-Sep-23 14:13 
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
trønderen21-Sep-23 7:29
trønderen21-Sep-23 7:29 
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
Richard MacCutchan20-Sep-23 23:03
mveRichard MacCutchan20-Sep-23 23:03 
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
jschell21-Sep-23 5:57
jschell21-Sep-23 5:57 
GeneralRe: How to get disk model and serial number for the disk Windows is installed on Pin
trønderen21-Sep-23 7:23
trønderen21-Sep-23 7:23 
AnswerRe: How to get disk model and serial number for the disk Windows is installed on Pin
Dave Kreskowiak20-Sep-23 14:23
mveDave Kreskowiak20-Sep-23 14:23 
AnswerRe: How to get disk model and serial number for the disk Windows is installed on Pin
Randor 20-Sep-23 23:34
professional Randor 20-Sep-23 23:34 
Questionwrite a progrrame create a calculator (using function) Pin
CHIRAG VAJA 202318-Sep-23 21:15
CHIRAG VAJA 202318-Sep-23 21:15 
AnswerRe: write a progrrame create a calculator (using function) Pin
Victor Nijegorodov18-Sep-23 21:26
Victor Nijegorodov18-Sep-23 21:26 
RantRe: write a progrrame create a calculator (using function) Pin
Richard Deeming18-Sep-23 22:23
mveRichard Deeming18-Sep-23 22:23 
AnswerRe: write a progrrame create a calculator (using function) Pin
jschell19-Sep-23 6:49
jschell19-Sep-23 6:49 
QuestionRe: write a progrrame create a calculator (using function) Pin
CPallini19-Sep-23 21:02
mveCPallini19-Sep-23 21:02 
AnswerRe: write a progrrame create a calculator (using function) Pin
Richard MacCutchan19-Sep-23 22:44
mveRichard MacCutchan19-Sep-23 22:44 
GeneralRe: write a progrrame create a calculator (using function) Pin
CPallini19-Sep-23 22:50
mveCPallini19-Sep-23 22:50 
JokeRe: write a progrrame create a calculator (using function) Pin
trønderen21-Sep-23 7:35
trønderen21-Sep-23 7:35 
QuestionPointer indirection Pin
Calin Negru14-Sep-23 4:01
Calin Negru14-Sep-23 4:01 
AnswerRe: Pointer indirection Pin
Mircea Neacsu14-Sep-23 4:06
Mircea Neacsu14-Sep-23 4:06 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.