Menu

check box

2002-12-01
2012-09-26
  • Nobody/Anonymous

    how can i made check box in C???

     
    • Nobody/Anonymous

      If you want to creste a chechbox on a windows program you can do this:

      LRESULT CALLBACK WndProc (        
        HWND mainWindow,
        UINT messages,
        WPARAM wParam,
        LPARAM lParam)
          {
      switch (messages)    {
          case WM_CREATE:

      hwndCheckBox01 = CreateWindow (TEXT ("button"), "CheckBox",
             WS_CHILD | WS_VISIBLE | WS_TABSTOP | BS_AUTOCHECKBOX,
              10, 210, 65, 10, mainWindow, (HMENU) 17, ((LPCREATESTRUCT) lParam)->hInstance, NULL) ;

      other cases:
      {stuff}

      }

      Tis is assuming that you have HWND hwndCheckBox01 declared somewhere on your code and your main window  is named as mainWindow.;

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.