Right
Using the RIGHT Function
In this tutorial you will learn how to use the RIGHT Function.
The RIGHT function returns a String containing a specified number of characters from the right side of a string.
=RIGHT( string, length )
string the value you wish to amend
length the length of characters you wish to return
In this example we will work with a Name.
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 |
R | i | c | h | a | r | d | | R | o | s | t |
The result is Rost.
Query
The results using a Query would be
FORM
In a Form you could set the Default Value of a Textbox to
=RIGHT("Richard Rost", 4)
VBA
In a Form add a TEXTBOX control and rename it "txtRight", then you could add the following in the Load Event.
Private Sub Form_Load()
txtRight = Right("Richard Rost", 4)
End Sub
Courses
Access Expert 14
Access 222
|
Access 308
|
Access 309
Seminars
Email
|
Relationship
|
Search
|
SQL 2
Tips
See this FREE Tip on Right.
See this FREE Tip on Right and many others.
Blog
See this Blog Post on the Right function.
Search
You can find more about this by searching the website.
By: Alex Hedley
Click here to sign up for more FREE tips
|