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. hwnd of other windows

hwnd of other windows

Scheduled Pinned Locked Moved C / C++ / MFC
4 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.
  • V Offline
    V Offline
    valec
    wrote on last edited by
    #1

    hi there just a quicky - i need to obtain the hwnd of all the other currently running programms on order to send then WM_* messages

    T M V 3 Replies Last reply
    0
    • V valec

      hi there just a quicky - i need to obtain the hwnd of all the other currently running programms on order to send then WM_* messages

      T Offline
      T Offline
      Tim Deveaux
      wrote on last edited by
      #2

      Try EnumWindows(). That should get you the hwnds for the top level windows of the desktop processes - you could also use EnumChildWindows() both for this and for getting child windows of the processes after you get their main windows.

      1 Reply Last reply
      0
      • V valec

        hi there just a quicky - i need to obtain the hwnd of all the other currently running programms on order to send then WM_* messages

        M Offline
        M Offline
        Michael Dunn
        wrote on last edited by
        #3

        You don't need to get their HWNDs, just call SendMessage() with HWND_BROADCAST as the first param.

        1 Reply Last reply
        0
        • V valec

          hi there just a quicky - i need to obtain the hwnd of all the other currently running programms on order to send then WM_* messages

          V Offline
          V Offline
          valec
          wrote on last edited by
          #4

          TAHNKS ,you are great exactly what i needed :)

          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