This is printed in a file or ? Please be more explicit.
If it is for a file, you can use fprintf and there are some parameters you can play on (for example the number of digits you want to see, the number of 'places' it will take, the alignment,...).
With this your format, it is not worked.
When I write this format strCommand.Format("%.-2f",Amount), it is left justified, but how can I make right justified ?(strCommand is CString so to print with dc.TexTout instruction)
I understand well the source of my problem,
When I use default Font, the numbers are right align, If I create Font : like i do, numbers are not align.
This is how I create my Font
font.CreateFont(-80,0,0,0,FW_NORMAL,FALSE,FALSE,0,ANSI_CHARSET,OUT_DEFAULT_PRECIS,CLIP_DEFAULT_PRECIS,DEFAULT_QUALITY,DEFAULT_PITCH|FF_ROMAN,"Times New Roman");
If you want to store the string entered, than you would at least need 4 bytes more and 1 extra if you want a terminating NULL character.
Hexadecimal numbers (read bytes) are represented with 2 characters: 0x'F''F' for 255 for example.
Behind every great black man...
... is the police. - Conspiracy brother
No, I want to store them as a numeric value not ascii.
In fact, my application is reading from the keyboard 4 bytes representing an address which will be sent to a microcontrolleer via the serial port.
That's unusual. I've only on suggestion. After this line: hr = tbWB->get_Document(&pDisp);
Place a breakpoint. When it is hit, enter the following expression in your watch window: hr, hr
This should show a text representation of the failure code (assuming failure) - perhaps this will give you a clue.
I'm developing an MDI-Application which uses a status bar and a dialog bar. The status bar is at the bottom of the window, the dialog bar is docked to the left side of the window.
My problem is, that the dialog bar goes down to the bottom of the window, i.e. the status bar does not span the whole width of the application window. Does anybody has an idea how I can make it the other way round, so that the dialog bar stops at the status bar?
there are no real languages installed on a PC.
you install an IDE, which allow you to program with one or one language. then, when you compile the code, it is turned into native language (for the microprocessor) or into an intermediate language like MSIL (for .NET framework) or Byte-Code (for Java Virtual Machine).
all depends on the development environement you're working on, and how it is installed.
for example with Visual Studio .NET 2003, it provides the MFC 7.1 only if you install Visual C++...