title: win32 button not showimg
body: <p>I tried to create a single button in a 500x500 window, the problem is, the button does not appear in the windows, and clicking the windows alone triggers the procedure/handler for the button:</p>
  
  <pre><code>#include &lt;windows.h&gt;
  
  LRESULT CALLBACK MainWindowHandler(HWND obj, UINT msg, WPARAM wParam, LPARAM lParam);
  LRESULT CALLBACK ButtonHandler(HWND obj, UINT msg, WPARAM wParam, LPARAM lParam);
  
  LPCSTR FrameClassName = "MainWindow";
  LPCSTR ButtonClassName = "Button";
  
  int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, PSTR lpCmdLine, int nCmdShow)
  {
  WNDCLASSEX Frame;
  HWND FrameHandle;
  WNDCLASSEX Button;
  HWND ButtonHandle;
  
  MSG Msg;
  
  Frame.cbSize        = sizeof(WNDCLASSEX);
      Frame.style         = 0;
      Frame.lpfnWndProc   = MainWindowHandler;
      Frame.cbClsExtra    = 0;
      Frame.cbWndExtra    = 0;
  Frame.hInstance     = hInstance;
  Frame.hIcon         = LoadIcon(NULL, IDI_APPLICATION);
  Frame.hCursor       = LoadCursor(NULL, IDC_ARROW);
  Frame.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
  Frame.lpszMenuName  = NULL;
  Frame.lpszClassName = FrameClassName;
      Frame.hIconSm       = LoadIcon(NULL, IDI_APPLICATION);
  
  Button.cbSize        = sizeof(WNDCLASSEX);
      Button.style         = 0;
      Button.lpfnWndProc   = ButtonHandler;
      Button.cbClsExtra    = 0;
      Button.cbWndExtra    = 0;
  Button.hInstance     = hInstance;
  Button.hIcon         = LoadIcon(NULL, IDI_APPLICATION);
  Button.hCursor       = LoadCursor(NULL, IDC_ARROW);
  Button.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
  Button.lpszMenuName  = FrameClassName;
  Button.lpszClassName = ButtonClassName;
      Button.hIconSm       = LoadIcon(NULL, IDI_APPLICATION);
  
  if(!RegisterClassEx(&amp;Frame))
  {
      MessageBox(NULL,"Registration Failure","ERROR",MB_ICONWARNING|             MB_OK);
      return 0;
  }
  if(!RegisterClassEx(&amp;Button))
  {
      MessageBox(NULL,"Registration Failure","ERROR",MB_ICONWARNING|             MB_OK);
      return 0;
  }
  
  FrameHandle = CreateWindowEx(WS_EX_CLIENTEDGE,
                       FrameClassName,
                       "Application",
                       WS_OVERLAPPEDWINDOW,
                       CW_USEDEFAULT, CW_USEDEFAULT, 500, 500,
                       NULL, NULL, hInstance, NULL);
  
  ButtonHandle = CreateWindowEx(0, ButtonClassName, "My Button",
      WS_CHILD | WS_VISIBLE, 250, 250, 30, 20, FrameHandle,
      (HMENU)FrameHandle, hInstance, NULL);
  
  SendDlgItemMessage(ButtonHandle, 12, WM_SETFONT,
      (WPARAM)GetStockObject(DEFAULT_GUI_FONT), MAKELPARAM(TRUE, 0));
  
  
  ShowWindow(FrameHandle, nCmdShow);
  UpdateWindow(FrameHandle);
  ShowWindow(ButtonHandle, nCmdShow);
  UpdateWindow(ButtonHandle);
  
  while(GetMessage(&amp;Msg,NULL,0,0)&gt;0)
  {
      TranslateMessage(&amp;Msg);
      DispatchMessage(&amp;Msg);
  }
  
  }
  
  LRESULT CALLBACK MainWindowHandler(HWND obj, UINT msg, WPARAM wParam, LPARAM lParam)
  {
  switch(msg)
  {
  case WM_LBUTTONDOWN:
      MessageBox(obj,"CLICKED!","BUTTON",0);
      break;
      case WM_CLOSE:
      DestroyWindow(obj);
          break;
      case WM_DESTROY:
      PostQuitMessage(0);
          break;
      default:
          return DefWindowProc(obj, msg, wParam, lParam);
  }
  return 0;
  }
  
  LRESULT CALLBACK ButtonHandler(HWND obj, UINT msg, WPARAM wParam, LPARAM lParam)
  {
  switch(msg)
  {
      case WM_CLOSE:
      DestroyWindow(obj);
          break;
      case WM_DESTROY:
      PostQuitMessage(0);
          break;
      default:
          return DefWindowProc(obj, msg, wParam, lParam);
  }
  return 0;
  }
  </code></pre>
  
  <p>What did i miss?</p>