Results 1 to 13 of 13

Thread: Subclassing a richtextbox

Threaded View

  1. #1

    Thread Starter
    Hyperactive Member Disiance's Avatar
    Join Date
    Sep 2004
    Location
    Denver, CO
    Posts
    439

    Resolved Subclassing a richtextbox

    I'm using the SetWindowLong API to subclass a richtextbox. The WinProc function that I have is:
    VB Code:
    1. Public Function WindowProc(ByVal hwnd As Long, ByVal msg As Long, ByVal wp As Long, ByVal lp As Long) As Long
    2.    ' Filter for messages of interest, but
    3.    ' allow default processing for most.
    4.    'Select Case msg
    5.          
    6.       'Case Else
    7.          ' Default processing...
    8.          WindowProc = DefWindowProc(Form1.txtDocument.hwnd, msg, wp, lp)
    9.    'End Select
    10. End Function
    As you can see the program, for now, is just there as another layer, not doing anything with the messages. I know this function is being called because of some debugging I did. My problem is that the richtextbox isn't getting of the messages, so it is not repainting, accepting focus, etc.
    Last edited by Disiance; Feb 8th, 2005 at 09:41 PM.
    "I don't want to live alone until I'm married" - M.M.R.P

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