So are you saying it is demoralizing to be given a link to the documentation?
I wasn't talking about that answer. Giving a link to documentation is a good start when you don't really know the answer, in hopes that the person who asked the question didn't checked it before.
I just Googled for the name of the API function that is in your question; why do you think that is difficult?
So with that I wasn't talking about me, it was in general, everything in that statement beside the part at the end, was something I observed over the time.
So you have the complete answer, why complain?
I didn't said the problem is solved. In the above message in responds to what Dave Kreskowiak said, I went into more details about the problem, as no one even tried to ask more question to understand the problem better, in case maybe it wasn't explained properly, which the founder of this website actually encourages to do so.
If a question is poorly phrased then either ask for clarification...
I'm glad that you actually read the whole thing, even tho there were some misunderstandings about the message it was meant to deliver.
"the debugger doesn't tell me anything because this code compiles just fine" - random QA comment
"Facebook is where you tell lies to your friends. Twitter is where you tell the truth to strangers." - chriselst
"I don't drink any more... then again, I don't drink any less." - Mike Mullikins uncle
I made the following change, and result is as expected:
double x = asDouble(-2147483648.0, 4); // instead of asDouble(-2147483648, 4);
Your code is not compiled for me, the error is:
error C4146: unary minus operator applied to unsigned type, result still unsigned
So, your conditional precision is OK, the problem is that 2147483648 is more than maximal unsigned int value, and applying unary minus operator to it gives compiler error in my case, and unexpected result in your case. Probably your compiler gives some warning for this line, don't ignore it.
In a dialog, i have added picture control from resource. in this i am displaying an image accordingly at the runtime which is working fine.
I need to zoom in / zoom out the displayed image according to mouse wheel move. I thought of adding window procedure to that picture control, so that i can handle mouse command over there. in MFC, i can see options and examples, but in win32 api, i dont know how to do that.
Just derive your own class from the CStatic (picture control is a static control), create the control member variable in the dialog for this picture control, and handle any Windows message you need in this derived class.
What is a common way to use NASM (or other assembly compilers) when developing windows applications. Do you integrate it with VisualStudio shell or you go down the path of always using the command line?
The usual way to integrate assembly files into a C++ project is to add the MASM "build customization" (right click a project, go to Build Dependencies > Build Customizations, check the box in front of MASM). Then you can include .asm files as normal sources without needing to do anything weird. You can install vsyasm and use YASM that way, if you prefer a more NASM-y syntax. Using NASM itself is possible, but as far as I know there's no nice integration like that, you can set it up manually as a custom build tool.