Hi,
Can anyone help? I'm trying to locate the 8th Character of TextBox 5.so if it says "C", TextBox58 produces "C58000"
Private Sub TextBox5_Change() If TextBox5.Value (8th character) = "C" Then Me.TextBox58.Value = "C58000" End If End Sub
Hi,
Can anyone help? I'm trying to locate the 8th Character of TextBox 5.so if it says "C", TextBox58 produces "C58000"
Private Sub TextBox5_Change() If TextBox5.Value (8th character) = "C" Then Me.TextBox58.Value = "C58000" End If End Sub
use mid function:
Private Sub TextBox5_Change() If MID(TextBox5.Value, 8, 1) = "C" Then Me.TextBox58.Value = "C58000" End If End Sub
Check this code and see if it helps you. Make some necessary changes as per your requirement.
If Len(TextBox1.Value) >= 8 Then If UCase(Mid(TextBox1.Value, 8, 1)) = "C" Then TextBox1.Value = "C58000" Else MsgBox "Character does not exists." End If Else MsgBox "String length less than 8 characters." End If
Click on "* Add Reputation" as a way to say thanks
Thanks, worked perfectly. Thank You :-)
Hi,
If my solution helped you, Click on "* Add Reputation" as a way to say thanks
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks