Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

problem to get HWnd to main frame

arvind17arvind17 Posts: 62Member
hi,
I am trying to use the CWindow::SendMessage()
I need HWND to use the above message. I need to send message to the OnLButtonDown which

I implemented in the View class.

Can sb give me the appr code.
What HWnd handle and how should I get to post the appr messages ?

I also tried using the CWnd::SendMessage. It only works in the CView class. In the other files I need to specify the handle to the window i need to send the message. I need to send to the view class - i am seeking what HWnd - handle to use ???

regards
-arvind

Comments

  • AsmGuru62AsmGuru62 Posts: 6,519Member
    [b][red]This message was edited by AsmGuru62 at 2003-3-18 7:54:2[/red][/b][hr]
    [b][red]This message was edited by AsmGuru62 at 2003-3-18 7:53:12[/red][/b][hr]
    : hi,
    : I am trying to use the CWindow::SendMessage()
    : I need HWND to use the above message. I need to send message to the OnLButtonDown which
    :
    : I implemented in the View class.
    :
    : Can sb give me the appr code.
    : What HWnd handle and how should I get to post the appr messages ?
    :
    : I also tried using the CWnd::SendMessage. It only works in the CView class. In the other files I need to specify the handle to the window i need to send the message. I need to send to the view class - i am seeking what HWnd - handle to use ???
    :
    : regards
    : -arvind
    :
    [blue][b]m_hWnd[/b] is a public member of any MFC class representing a window, so you can access it just by using . or -> operators:

    AfxGetMainWnd()->m_hWnd[/blue]




Sign In or Register to comment.