I'm in the process of writing a win32 program in Dev-C++ distributed by Orwell. In relation to that a problem has occurred. When I'm writing a program in C++ console, I write the following code to output multiple variables:
cout << "The value of x is: " << x << " and the value of y is: " << y << endl;
When I want a output, I for instance write the following code:
The this case I use the text as a variable. My question is now, how do I output from more than one variable and get the same result as with the console?
My guess was something like CreateWindow("STATIC", "Here is the text: " text | " and the other text: " text2, WS_VISIBLE | WS_CHILD, x, y, h, w, hwnd, (HMENU) ID, NULL, NULL); - but I know that's not how you do it.
The GDI analog to printing to a console window is TextOut() or DrawText(). And actually, those functions also work with consoles too. Consoles have a HWND, which is the key to getting that to work.