Link to home
Start Free TrialLog in
Avatar of LucyTaylor
LucyTaylor

asked on

Editing a TextBox

Hello, I have a textbox that displays certain data when certain checkboxes are checked, what i need to know is how do i edit the data in the textbox.  For example if the textbox reads 'Thereare two numbers"  how would i be able to edit the display to add a space between there and are.  Thanks
Avatar of appari
appari
Flag of India image

try something like this

Private Sub Command1_Click()
Dim str
str = "Thereare two numbers"
Mid(str, 6) = " " & Mid(str, 6)
Debug.Print str
End Sub

replace str with Textbox name


Avatar of Ryan Chong
or

Dim str
str = Replace$("Thereare two numbers","Thereare","There are")
Debug.Print str

?
Avatar of LucyTaylor
LucyTaylor

ASKER

I am sorry, i might have confused you on the question, i just need to be able to edit the data in the text box, when the data is displayed on the userform i need to be able to click on the textbox to make changes.
How do you display your data? Link/ Bound to a Data Control? Is it a Query from many tables or just from single table?
Linked
So, back to your problem.

Are you mean you can't change the value (Text) in the TextBox Bound to a DataSource?
Yea
ASKER CERTIFIED SOLUTION
Avatar of Ryan Chong
Ryan Chong
Flag of Singapore image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
The Locked property was set to to true, thanks
You're welcome :)