Results 1 to 2 of 2

Thread: How to scroll text with API

  1. #1

    Thread Starter
    Member
    Join Date
    Apr 2000
    Posts
    45

    Question

    I am using RichTextBox and I am looking for API that will get line number and will scroll the text to the line position.

    Thanx

    VB6 SP4
    VBmaster

  2. #2
    Addicted Member KrishnaSantosh's Avatar
    Join Date
    Feb 2001
    Location
    Coimbatore
    Posts
    210
    Try This

    Private Const EM_GETLINECOUNT = &HBA

    Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long

    Private Sub Command1_Click()
    Label1.Caption = SendMessage(Text1.hwnd, EM_GETLINECOUNT, 2&, 0)
    End Sub

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