locked
How to hook OnDocumentComplete()? RRS feed

  • Question

  • Hello,

    We are doing some customization of IE and need to work also from another process (not just BHO). Therefore, we are trying to use SetWinEventHook() to hook the events.

    We can hook some standard event. For example, IE fires EVENT_OBJECT_REORDER as described in https://blogs.msdn.microsoft.com/ie/2008/12/10/new-accessibility-features-in-ie8/.The value for EVENT_OBJECT_REORDER is 0x8004.

    But if we want to capture specifically OnDocumentComplete()'s corresponding event, what is the parameters we should pass to SetWinEventHook()? I haven't been able to find it. Was it discussed in MSDN or anywhere?

    Bob

    Friday, September 16, 2016 10:51 AM

Answers

  • Hi Bobby_9991,

    thanks for posting here.

    >>But if we want to capture specifically OnDocumentComplete()'s corresponding event, what is the parameters we should pass to SetWinEventHook()? I haven't been able to find it. Was it discussed in MSDN or anywhere?

    For this case, you could set first two parameters to EVENT_MIN and EVENT_MAX. Then set the forth parameter to the pointer to the OnDocumentComplete function.

    For more information, please refer to this document.

    https://msdn.microsoft.com/en-us/library/windows/desktop/dd373640(v=vs.85).aspx

    Hope this could be help of you.

    Best Regards,

    Sera Yu


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.

    Tuesday, September 20, 2016 2:58 AM