Results 1 to 3 of 3

Thread: scrolling

  1. #1

    Thread Starter
    Frenzied Member markman's Avatar
    Join Date
    Nov 2000
    Location
    Florida.
    Posts
    1,197

    scrolling

    I have 2 identical richtextboxes (rtb1 And rtb2).They both have vertical scroll bars. I want to make rtb2 scroll to where rtb1 is scrolled to. Say rtb is scrolled to line 123. I want rtb2 to scrol to line 123. Get the picture?
    retired member. Thanks for everything

  2. #2
    rickm
    Guest
    What is your ultimate purpose?

  3. #3
    Addicted Member csammis's Avatar
    Join Date
    Mar 2001
    Location
    /dev/null
    Posts
    226
    Use the SendMessage API to send the EM_LINESCROLL message to the RichTextBox you want to scroll. (I don't know the number value of EM_LINESCROLL...if you have a flavor of C++ on your machine, it's in "winuser.h")

    SendMessage RichTextBox2.hWnd,EM_LINESCROLL,[number of columns to scroll horizontally],[number of lines to scroll vertically]
    Things I've Said:
    "Life's funny like that...elephants can wear frilly lace panties, and Dubya still looks like a monkey in a big chair"
    "Take four goats and strap one to each foot of a llama. Presto, goat-powered llama!"
    "You want to get me to work more, get me a Coke. No? Then deal with inferior garbage, I'm not coding another line and your clients can go to......thanks, I'd love a Coke right about now!"

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