Results 1 to 4 of 4

Thread: Turn Off the Insert Key ?

  1. #1

    Thread Starter
    Member
    Join Date
    Aug 2000
    Posts
    39

    Question

    I have a richtext box which I am using as kind of a text editor (thanks to Joachim Anderson). I need to be able to force the richtext box into insertmode, without hitting the insert key so that text is overwritten without displacing anything else on the file.

    Keyascii doesn't appear to pick up the insert key so I can't do it that way.

    Any ideas anyone ?

  2. #2
    PowerPoster 2.0 Negative0's Avatar
    Join Date
    Jun 2000
    Location
    Southeastern MI
    Posts
    4,367
    Usually the keyascii wont pick up the special codes. Try and use the KeyCode from the keydown event.

    Hope this helps,

  3. #3

  4. #4
    Guest
    A little ugly, but works well.
    Code:
    Private Sub Command1_Click()
        RichTextBox1.SetFocus
        SendKeys "{INSERT}"
    End Sub
    You can also use the KeyCode event. The code for Insert is vbKeyInsert.

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