If I have some text, e.g. "elephant" stored in the variable MyString, how would I extract the last three characters from the variable MyString to get "ant"?
In other languages, the function Right(MyString, 3) would do this but there doesn't seem to be such a function in LiveCode.
Many thanks,
Steven
Extracting part of a string from a variable
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
-
- Posts: 14
- Joined: Mon Jan 12, 2015 7:55 pm
Re: Extracting part of a string from a variable
Code: Select all
on mouseUp
put char -3 to -1 of myString
end mouseUp
-
- Posts: 14
- Joined: Mon Jan 12, 2015 7:55 pm