Results 1 to 11 of 11

Thread: Monitor another app

  1. #1

    Thread Starter
    Frenzied Member nishantp's Avatar
    Join Date
    Jan 2001
    Location
    Where you least expect me to be
    Posts
    1,375

    Monitor another app

    How would I be able to monitor another app? For-instance, determine if it is still running or not? I dont really know much about APIs and im pretty stumped.

    Any yes, i did search the forums. I wasnt sure what to search for so i didnt find anything.

    Thanks,
    Nishant
    You just proved that sig advertisements work.

  2. #2
    PowerPoster abdul's Avatar
    Join Date
    Dec 2000
    Location
    Ontario,Canada
    Posts
    2,827
    I think, you'll have to install a hook for that app.
    I'll try to find some more info about that.
    Baaaaaaaaah

  3. #3
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441

    Well

    GETWINDOW something or other API call...
    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

  4. #4

    Thread Starter
    Frenzied Member nishantp's Avatar
    Join Date
    Jan 2001
    Location
    Where you least expect me to be
    Posts
    1,375

    Re: Well

    Originally posted by James Stanich
    GETWINDOW something or other API call...
    It would seem that function is for MDI children and parents.
    You just proved that sig advertisements work.

  5. #5
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441

    Well

    That may not be it, I'll search...
    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

  6. #6
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441

    Well

    Here the API:

    Option Explicit
    Private Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" (ByVal hWnd1 As Long, ByVal hWnd2 As Long, ByVal lpsz1 As String, ByVal lpsz2 As String) As Long
    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

  7. #7
    AngelFire
    Guest

    Re: Monitor another app

    Originally posted by nishantp
    How would I be able to monitor another app? For-instance, determine if it is still running or not? I dont really know much about APIs and im pretty stumped.

    Any yes, i did search the forums. I wasnt sure what to search for so i didnt find anything.

    Thanks,
    Nishant
    Is the app that you want to monitor has title? If it has, try FindWindow or FindWindowEx to get it handle to determine the app run or not.

    PHP Code:
    Public Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As StringByVal lpWindowName As String) As Long
    Public Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" (ByVal hWnd1 As LongByVal hWnd2 As LongByVal lpsz1 As StringByVal lpsz2 As String) As Long 

  8. #8

    Thread Starter
    Frenzied Member nishantp's Avatar
    Join Date
    Jan 2001
    Location
    Where you least expect me to be
    Posts
    1,375
    That should work. Thanks a lot James.
    You just proved that sig advertisements work.

  9. #9

    Thread Starter
    Frenzied Member nishantp's Avatar
    Join Date
    Jan 2001
    Location
    Where you least expect me to be
    Posts
    1,375
    Thanks AngleFire also.
    You just proved that sig advertisements work.

  10. #10
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441

    Well

    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

  11. #11
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527

    Well

    To be technical, that isn't monitoring another app.

    You can use that to find the handle of another app, but I suggest you hook it.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width