francois.lemarie
Board Regular
- Joined
- Mar 24, 2010
- Messages
- 54
I need to prevent a user to modify a textbox (Control ActiveX). Does anyboday know how to do ?
Sheets("Sheet1").TextBox1.Enabled = False 'Can't edit Textbox1
Or to toggle enabled True\False...
Sheets("Sheet1").TextBox1.Enabled = Not Sheets("Sheet1").TextBox1.Enabled
Private Sub TextBox1_KeyDown _
(ByVal KeyCode As MSForms.ReturnInteger, ByVal Shift As Integer)
KeyCode = 0
End Sub