VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



Make the textbox Locked for inputs and NOT grey

by Martin Tonek (2 Submissions)
Category: Custom Controls/Forms/Menus
Compatability: Visual Basic 3.0
Difficulty: Unknown Difficulty
Date Added: Wed 3rd February 2021
Rating: (60 Votes)

Let you lock your textbox for inputs and it will NOT be grey, but will be able to highlightning and scrolling. One line code is all you need!

Inputs
add a textbox named Text1. Thats IT!!
Assumes
None, More simple then this it will never be! well if you cant see all text.. just change multiline to true in textbox properties. But that you already now!! ;-) More sources avalible on http://hem.passagen.se/tonek/vb
Code Returns
A textbox that you can highlight and scroll but not change

Rate Make the textbox Locked for inputs and NOT grey

'// Please visit my homepage http://hem.passagen.se/tonek/vb
'// and check out other sources i made..
'//     Martin Tonek 
Private Sub Form_Load()
'// This will lock the control so you cant make any changes
'// in runmode , false open it up.. default is false
Text1.Locked = True
Text1.Text = "you can scroll and highlight the text in the control" & _
" but you can't edit it. The program can still modify the text by " & _
"changing the Text property"
End Sub
'// I find it in the helpfile...so now you now how. Also want to add that
'// all people using the keyascii code.. this one is better...
'// neet little code free to use
'// Wonder why people is so upset. I just tell this one..
'// so a lot of people that do not use it when it is avalible may use it.

Download this snippet    Add to My Saved Code

Make the textbox Locked for inputs and NOT grey Comments

No comments have been posted about Make the textbox Locked for inputs and NOT grey. Why not be the first to post a comment about Make the textbox Locked for inputs and NOT grey.

Post your comment

Subject:
Message:
0/1000 characters