Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Webbrowser repaint??

Webbrowser repaint??

Scheduled Pinned Locked Moved C / C++ / MFC
helptutorialquestion
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    dooly
    wrote on last edited by
    #1

    Dear Developer I'm developing webbrowser using CHtmlView. But i don't know handler that received WM_PAINT message. For example LRESULT CMainFrame::WindowProc(UINT message, WPARAM wParam, LPARAM lParam) { // TODO: Add your specialized code here and/or call the base class if( message == WM_NOTIFY || message == WM_PAINT ) { // paint code here } } return CFrameWnd::WindowProc(message, wParam, lParam); } Above example does not repaint properly. For example "Scroll event" When i draw in my program and scroll the window then doesn't repaint. Please help. Thanks in advance dooly

    P 1 Reply Last reply
    0
    • D dooly

      Dear Developer I'm developing webbrowser using CHtmlView. But i don't know handler that received WM_PAINT message. For example LRESULT CMainFrame::WindowProc(UINT message, WPARAM wParam, LPARAM lParam) { // TODO: Add your specialized code here and/or call the base class if( message == WM_NOTIFY || message == WM_PAINT ) { // paint code here } } return CFrameWnd::WindowProc(message, wParam, lParam); } Above example does not repaint properly. For example "Scroll event" When i draw in my program and scroll the window then doesn't repaint. Please help. Thanks in advance dooly

      P Offline
      P Offline
      pba_
      wrote on last edited by
      #2

      The CHtmlView is just a container for the WebBrowser control .To intercept the events you must connect to the events of the HTML document that is displayed in the control .Also , you can intercept some messages via WM_NOTIFY .

      D 1 Reply Last reply
      0
      • P pba_

        The CHtmlView is just a container for the WebBrowser control .To intercept the events you must connect to the events of the HTML document that is displayed in the control .Also , you can intercept some messages via WM_NOTIFY .

        D Offline
        D Offline
        dooly
        wrote on last edited by
        #3

        Hi Thanks for your reply. But i don't know how connect to the event. Have you some sample code? Or Have you method to catch scrollbar event? Thanks in advance again. dooly

        P 1 Reply Last reply
        0
        • D dooly

          Hi Thanks for your reply. But i don't know how connect to the event. Have you some sample code? Or Have you method to catch scrollbar event? Thanks in advance again. dooly

          P Offline
          P Offline
          pba_
          wrote on last edited by
          #4

          check this address : http://msdn.microsoft.com/workshop/c-frame.htm?/workshop/browser/default.asp You can catch all the events for an DHTML object , so you can handle the scroll event also ( this event is received by the BODY element )

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups