Here's my window creation code.

Code:
#include <windows.h>

// Declare WndProcedure




LRESULT CALLBACK WndProcedure(HWND hWnd, UINT uMsg,
			   WPARAM wParam, LPARAM lParam);

INT WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
               LPSTR lpCmdLine, int nCmdShow)
{
	MSG        Msg;
	HWND       hWnd;
	HRESULT	   hRet;
	WNDCLASSEX WndClsEx;

	// Populate the WNDCLASSEX structure
	WndClsEx.cbSize        = sizeof(WNDCLASSEX);
	WndClsEx.style         = CS_HREDRAW | CS_VREDRAW;
	WndClsEx.lpfnWndProc   = WndProcedure;
	WndClsEx.cbClsExtra    = 0;
	WndClsEx.cbWndExtra    = 0;
	WndClsEx.hIcon         = LoadIcon(NULL, IDI_APPLICATION);
	WndClsEx.hCursor       = LoadCursor(NULL, IDC_ARROW);
	WndClsEx.hbrBackground = (HBRUSH)(COLOR_HIGHLIGHT+1);//(HBRUSH)GetStockObject(WHITE_BRUSH);
	WndClsEx.lpszMenuName  = NULL;
	WndClsEx.lpszClassName = "MyWindow";
	WndClsEx.hInstance     = hInstance;
	WndClsEx.hIconSm       = LoadIcon(NULL, IDI_APPLICATION);

	
 /* COLOURS :)
COLOR_ACTIVEBORDER
COLOR_ACTIVECAPTION
COLOR_APPWORKSPACE
COLOR_BACKGROUND
COLOR_BTNFACE
COLOR_BTNSHADOW
COLOR_BTNTEXT
COLOR_CAPTIONTEXT
COLOR_GRAYTEXT
COLOR_HIGHLIGHT
COLOR_HIGHLIGHTTEXT
COLOR_INACTIVEBORDER
COLOR_INACTIVECAPTION
COLOR_MENU
COLOR_MENUTEXT
COLOR_SCROLLBAR
COLOR_WINDOW
COLOR_WINDOWFRAME
COLOR_WINDOWTEXT 
*/
 
 
 
 // Register the class
	RegisterClassEx(&WndClsEx);





	// Create the window object
	hWnd = CreateWindow("MyWindow",
			  "Rich's Window",
			  WS_OVERLAPPEDWINDOW,
			  CW_USEDEFAULT,
			  CW_USEDEFAULT,
			  CW_USEDEFAULT,
			  CW_USEDEFAULT,
			  NULL,
			  NULL,
			  hInstance,
			  NULL);
			  




			  
			  
	
	// Verify window creation
	if( !hWnd ) // If the window was not created,
		return 0; // stop the application

	// Show the window
	ShowWindow(hWnd, SW_SHOWNORMAL);
	UpdateWindow(hWnd);

	//  message pump
	while( (hRet = GetMessage( &Msg, NULL, 0, 0 )) != 0)
	{ 
		if (hRet == -1)
		{
        // handle the error and possibly exit
		}
		else
		{
			TranslateMessage(&Msg); 
			DispatchMessage(&Msg); 
		}
	}

return 0;

}



LRESULT CALLBACK WndProcedure(HWND hWnd, UINT Msg,
			   WPARAM wParam, LPARAM lParam)
{
    switch(Msg)
    {
    case WM_DESTROY:
        // user wants to exit
        PostQuitMessage(WM_QUIT);
        break;
    default:
        // Hand off unprocessed messages to DefWindowProc
        return DefWindowProc(hWnd, Msg, wParam, lParam);
    }
    
    return 0;
}
I am unsure of how to put it in a class so I can create as many windows as i want in an application.

-What do i do with the message handler? Do i declare it static
-Once classed to i added member functions like set window caption, using sendmessage.

A description of how to do it would be fantastic , i want to try and do as much myself, its the only way i learn.