Results 1 to 9 of 9

Thread: Message Handling

  1. #1

    Thread Starter
    Fanatic Member faisalkm's Avatar
    Join Date
    Oct 2000
    Location
    Germany
    Posts
    752

    Cool

    Hey

    I want to add a menu to another application and handle the messages here in vb . can i do it?. I was able to add a menu but not handle it?


    Faisal
    Faisal Muhammed
    Homepage:I Started making it in 1994 ...Still Under Construction
    Using

    Visual Basic 6.0 Enterprise SP5
    Embedded Visual Basic 3.0
    SQL Server 2000
    Windows 2000 Proff
    Delphi 6.0


    Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.

  2. #2
    Hyperactive Member tumblingdown's Avatar
    Join Date
    Mar 2000
    Posts
    362
    You've found you can AppendMenu, but when you SetWindowLong (with the other apps window hwnd, and your WindowProc) is returning zero - correct?

    You will need to use Hooks to respond to the WM_SYSCOMMAND from the other app. You cannot do this in VB, as you need to create a dll (c++) that is injected into a foreign process space. Once you have this dll, it can call your custom window proc (as in normal subclassing). After your processing, your proc uses the dll to pass back to any other Global Hooks knocking around.


    td.
    "One logical slip and an entire scientific edifice comes tumbling down." - Robert M. Pirsig


    [email protected]

    "but if Einstein is right and God is in the details, reality requires that we sometimes get religion." - Scott Meyers.

  3. #3

    Thread Starter
    Fanatic Member faisalkm's Avatar
    Join Date
    Oct 2000
    Location
    Germany
    Posts
    752

    Exclamation

    Hey,

    Thnks for the information. Could u tell me how can i create this dll or there is a readymade one?

    Faisal
    Faisal Muhammed
    Homepage:I Started making it in 1994 ...Still Under Construction
    Using

    Visual Basic 6.0 Enterprise SP5
    Embedded Visual Basic 3.0
    SQL Server 2000
    Windows 2000 Proff
    Delphi 6.0


    Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.

  4. #4
    Hyperactive Member tumblingdown's Avatar
    Join Date
    Mar 2000
    Posts
    362
    I can recomend a v.good book.

    Win32 API Programming with Visual Basic. (O'Reilly, ISBN 1-56592-631-5).

    To start friggin around with this kind of stuff, really does take balls, you will need a reference like this to do it (This is the kind of stuff that can give Dan Appleman a bad day). It is written by a guy called Steven Roman.

    It comes with a dll to do what you want to do, and examples.


    td.
    "One logical slip and an entire scientific edifice comes tumbling down." - Robert M. Pirsig


    [email protected]

    "but if Einstein is right and God is in the details, reality requires that we sometimes get religion." - Scott Meyers.

  5. #5

    Thread Starter
    Fanatic Member faisalkm's Avatar
    Join Date
    Oct 2000
    Location
    Germany
    Posts
    752

    Cool

    Hey,

    I'm in a project regarding this. No time to buy a book..I hope u understand my situation. Could u guide me where could i get this dll?

    Faisal

    Faisal Muhammed
    Homepage:I Started making it in 1994 ...Still Under Construction
    Using

    Visual Basic 6.0 Enterprise SP5
    Embedded Visual Basic 3.0
    SQL Server 2000
    Windows 2000 Proff
    Delphi 6.0


    Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.

  6. #6
    Hyperactive Member tumblingdown's Avatar
    Join Date
    Mar 2000
    Posts
    362
    I can send you the dll. But i really recomend you DON'T try this stuff without reading up on it. It's not just a question of using the DLL, you really have to know stuff that's going on under the hood.


    td.

    "One logical slip and an entire scientific edifice comes tumbling down." - Robert M. Pirsig


    [email protected]

    "but if Einstein is right and God is in the details, reality requires that we sometimes get religion." - Scott Meyers.

  7. #7

    Thread Starter
    Fanatic Member faisalkm's Avatar
    Join Date
    Oct 2000
    Location
    Germany
    Posts
    752

    Smile

    Nice to hear that you have the dll. I know i may jump into foolishness if i do it without learning it very well. So what to do? The deadline is looking at me...I hope i have good understanding of message subclassing. will this help doing that..please help...now u r the only one who can help me..if u could do some help on how to use this dll then i would be very thankful to u

    Faisal
    Faisal Muhammed
    Homepage:I Started making it in 1994 ...Still Under Construction
    Using

    Visual Basic 6.0 Enterprise SP5
    Embedded Visual Basic 3.0
    SQL Server 2000
    Windows 2000 Proff
    Delphi 6.0


    Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.

  8. #8
    Hyperactive Member tumblingdown's Avatar
    Join Date
    Mar 2000
    Posts
    362
    i'm facing deadlines myself (already missed one). I know how your position. If you know subclassing, then you should be able to digest the two chapters in an hour. Amazon should be able to deliver within a day...

    I can mail you dll if you want, but your on your own (at least till i'm not so busy).


    td.
    "One logical slip and an entire scientific edifice comes tumbling down." - Robert M. Pirsig


    [email protected]

    "but if Einstein is right and God is in the details, reality requires that we sometimes get religion." - Scott Meyers.

  9. #9
    yay gay PT Exorcist's Avatar
    Join Date
    Apr 2002
    Location
    . . . my reason of shame
    Posts
    2,729
    i would like to get it? could you plz send me to [email protected]?
    \m/\m/

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