Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Check Box & ShellExecute Question.

Check Box & ShellExecute Question.

Scheduled Pinned Locked Moved C / C++ / MFC
questionc++jsontutorial
10 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Suresh H
    wrote on last edited by
    #1

    How to check if the check box is checked or not in win 32 App ??? We use to use member of the check box to check if its checked or not checked in MFC m_CkBox == TRUE how to do it in win 32 app ???? I want to open the text file in note pad how to do it ??? This works in MFC ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); How to do it in Win 32 API ??? I am not able to use ShellExecute in win 32 App Thanking you,:) Suresh HC

    N H 2 Replies Last reply
    0
    • S Suresh H

      How to check if the check box is checked or not in win 32 App ??? We use to use member of the check box to check if its checked or not checked in MFC m_CkBox == TRUE how to do it in win 32 app ???? I want to open the text file in note pad how to do it ??? This works in MFC ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); How to do it in Win 32 API ??? I am not able to use ShellExecute in win 32 App Thanking you,:) Suresh HC

      N Offline
      N Offline
      Nibu babu thomas
      wrote on last edited by
      #2

      Suresh H wrote:

      How to check if the check box is checked or not in win 32 App ??? We use to use member of the check box to check if its checked or not checked in MFC m_CkBox == TRUE how to do it in win 32 app ????

      BM_GETCHECK.

      Suresh H wrote:

      ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL);

      Suresh H wrote:

      How to do it in Win 32 API ??? I am not able to use ShellExecute in win 32 App

      See what GetLastError returns. See the documentation for further details.


      Nibu thomas A Developer Programming tips[^]  My site[^]

      S 1 Reply Last reply
      0
      • S Suresh H

        How to check if the check box is checked or not in win 32 App ??? We use to use member of the check box to check if its checked or not checked in MFC m_CkBox == TRUE how to do it in win 32 app ???? I want to open the text file in note pad how to do it ??? This works in MFC ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); How to do it in Win 32 API ??? I am not able to use ShellExecute in win 32 App Thanking you,:) Suresh HC

        H Offline
        H Offline
        Hamid Taebi
        wrote on last edited by
        #3

        See BM_GETCHECKand BM_GETSTATE


        WhiteSky


        S 1 Reply Last reply
        0
        • N Nibu babu thomas

          Suresh H wrote:

          How to check if the check box is checked or not in win 32 App ??? We use to use member of the check box to check if its checked or not checked in MFC m_CkBox == TRUE how to do it in win 32 app ????

          BM_GETCHECK.

          Suresh H wrote:

          ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL);

          Suresh H wrote:

          How to do it in Win 32 API ??? I am not able to use ShellExecute in win 32 App

          See what GetLastError returns. See the documentation for further details.


          Nibu thomas A Developer Programming tips[^]  My site[^]

          S Offline
          S Offline
          Suresh H
          wrote on last edited by
          #4

          Thanks Thomas for the response & for the Solution. Its working now I just did if (::SendMessage(hwndCheckBox,BM_GETCHECK,0,0)==BST_CHECKED) to check the status. But still for this I am getting error ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); Error:- : error C2065: 'ShellExecute' : undeclared identifier Error executing cl.exe.

          N 1 Reply Last reply
          0
          • H Hamid Taebi

            See BM_GETCHECKand BM_GETSTATE


            WhiteSky


            S Offline
            S Offline
            Suresh H
            wrote on last edited by
            #5

            Thanks White Sky for the response. info is very use full. But still for this I am getting error for this statement ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); Error:- : error C2065: 'ShellExecute' : undeclared identifier Error executing cl.exe.

            H 1 Reply Last reply
            0
            • S Suresh H

              Thanks Thomas for the response & for the Solution. Its working now I just did if (::SendMessage(hwndCheckBox,BM_GETCHECK,0,0)==BST_CHECKED) to check the status. But still for this I am getting error ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); Error:- : error C2065: 'ShellExecute' : undeclared identifier Error executing cl.exe.

              N Offline
              N Offline
              Nibu babu thomas
              wrote on last edited by
              #6

              Suresh H wrote:

              But still for this I am getting error ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); Error:- : error C2065: 'ShellExecute' : undeclared identifier Error executing cl.exe.

              Header: Declared in Shellapi.h. Import Library: Shell32.lib.


              Nibu thomas A Developer Programming tips[^]  My site[^]

              S 1 Reply Last reply
              0
              • S Suresh H

                Thanks White Sky for the response. info is very use full. But still for this I am getting error for this statement ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); Error:- : error C2065: 'ShellExecute' : undeclared identifier Error executing cl.exe.

                H Offline
                H Offline
                Hamid Taebi
                wrote on last edited by
                #7

                I think your problem is sovle with Nibu babu thomas answer,right;)


                WhiteSky


                S 1 Reply Last reply
                0
                • N Nibu babu thomas

                  Suresh H wrote:

                  But still for this I am getting error ShellExecute(NULL, "open", FileName ,NULL, NULL, SW_SHOWNORMAL); Error:- : error C2065: 'ShellExecute' : undeclared identifier Error executing cl.exe.

                  Header: Declared in Shellapi.h. Import Library: Shell32.lib.


                  Nibu thomas A Developer Programming tips[^]  My site[^]

                  S Offline
                  S Offline
                  Suresh H
                  wrote on last edited by
                  #8

                  Hi Nibu Thomas , Its working now, as u said I include only Shellapi.h its working. Thank you very much.

                  1 Reply Last reply
                  0
                  • H Hamid Taebi

                    I think your problem is sovle with Nibu babu thomas answer,right;)


                    WhiteSky


                    S Offline
                    S Offline
                    Suresh H
                    wrote on last edited by
                    #9

                    yes ........White Sky.....its done ...Thanks for the responce.:)

                    H 1 Reply Last reply
                    0
                    • S Suresh H

                      yes ........White Sky.....its done ...Thanks for the responce.:)

                      H Offline
                      H Offline
                      Hamid Taebi
                      wrote on last edited by
                      #10

                      You're welcome:)


                      WhiteSky


                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups