How to detect mouse click in the child window created by the CHTMLEDITVIEW VC++. NET

Hi,

Seek help urgently.

Anyone knows how to detect mouse clicks in the child window view that was created by the CHTMLEDITVIEW (base class) MFC of VC++.NET 2003

i.e. When i clicked "File-> Open-> " powerpoint.ppt" ( document )

The powerpoint slide will open in a MDIChildWnd. ( if i am not wrong, it is a web browser view ) I tried to use the WM_ONLBUTTONDOWN events provided in the CChildFrame, but i could not detect any mouse clicks.

I have tried searching for solution but i couldnt find any.

Can anyone help im stucked in this problem for almost a week.

Really appreciate if anyone could help.

tks.

terr




Answer this question

How to detect mouse click in the child window created by the CHTMLEDITVIEW VC++. NET

  • jam281

    im sorry about that.

    Ok .. thanks so much.

    awaiting for your good news.

    Thanks.

    terr



  • reichard

    Hi brian,

    tks for the tips on that.

    I used the Spy++ to check which class is it when i open powerpoint.ppt. It is "paneClassDC".

    I read on some examples is that people used the FindWindowEx() to find the exact window class. and after which used PostMessage() to check for mouseclicks events.

    1. But I am rather new to C++. So I have a problem on where to insert this FindWindowEx() into my project. Is it the CMainFrame.ccp, CChildFrame.ccp, CXXXView.cpp, CXXXDoc.ccp, CXXX.ccp

    2. Next, HWND FindWindowEx(
    HWND hwndParent,
    HWND hwndChildAfter,
    LPCTSTR lpszClass,
    LPCTSTR lpszWindow
    );

    Where can i get the HWND for the child as well as the class name and window name

    will u be able to give me some hints or advices or examples.

    Thanks so much.

    terr



  • Dylan Barber

    Sorry, your questions are going outside the scope of this forum, which is to assist on using VC++ as a tool. I could try to scrape the cobwebs off of my memory of this but you would be better off asking a forum populated by UI experts. I would continue your investigation with these guys: http://msdn.microsoft.com/newsgroups/default.aspx dg=microsoft.public.win32.programmer.ui&lang=en&cr=US
  • K_L

    Use Spy++ to figure out which window is receiving the mouse event.
  • How to detect mouse click in the child window created by the CHTMLEDITVIEW VC++. NET