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. Callback in MFC

Callback in MFC

Scheduled Pinned Locked Moved C / C++ / MFC
c++tutorial
3 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
    SiddharthAtw
    wrote on last edited by
    #1

    How to implement a callback function in MFC or how to enumerate Process in MFC

    A D 2 Replies Last reply
    0
    • S SiddharthAtw

      How to implement a callback function in MFC or how to enumerate Process in MFC

      A Offline
      A Offline
      Antti Keskinen
      wrote on last edited by
      #2

      Callback functions are implemented in MFC just as they are implemented in Win32: you create your own function that follows the guidelines specified by the documentation (function return value & parameters), then give this function's address (it's name) as a parameter for the routine that starts the enumeration. The routine will call your function with the appropriate parameters for each object or instance it finds. In the case of process enumeration, these objects/instances are the different processes running in the system. The PS API offers an alternative way: it fills a specified DWORD array with the process identifiers. See this page[^] for an example. -Antti Keskinen ---------------------------------------------- The definition of impossible is strictly dependant on what we think is possible.

      1 Reply Last reply
      0
      • S SiddharthAtw

        How to implement a callback function in MFC or how to enumerate Process in MFC

        D Offline
        D Offline
        David Crow
        wrote on last edited by
        #3

        SiddharthAtw wrote: ...how to enumerate Process in MFC See if Process32First() and Process32Next() help.


        A rich person is not the one who has the most, but the one that needs the least.

        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