How to get name of the currently running applications ?

Discussion in 'Mac Programming' started by neha1, Dec 17, 2008.

  1. neha1 macrumors newbie

    Joined:
    Sep 24, 2008
    #1
    hi all

    working on Qt4.4.2 on my mac intel machine. i have to develop an application to get the names of the applications that are currently running on my system.

    Is there any API in carbon to get the names of the currently running applications or any other alternative.


    Thanks & Regards

    Neha:)
     
  2. kainjow Moderator emeritus

    kainjow

    Joined:
    Jun 15, 2000
    #2
    GetNextProcess() and CopyProcessName() should do it.

    Are you sure Qt doesn't have an API for this?
     
  3. ChrisA macrumors G4

    Joined:
    Jan 5, 2006
    Location:
    Redondo Beach, California
    #3
    You can run the "ps" command in a shell and capture it's output. This is portable across all *nix systems.
     
  4. neha1 thread starter macrumors newbie

    Joined:
    Sep 24, 2008

Share This Page