What is the quickest easiest way to turn the string "somepicture.jpg" into the string "somepicture" with lingo.
So for any string of a file name removes the extension and the "."
Heres how to hack off the last four Characters from a string:
----
mystring = "somepicture.jpg"
mystring = mystring.char[1..mystring.length - 4]
----
mystring is the string. All it does is set mystring to itself minus the last 4 characters. Have fun.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.