class String

Parent: Object | Class Index
Methods:to_l |
Sample Code:stringtests.rb |

The String class contains a method used to parse a string as a length value.

Instance Methods

to_l
The to_l method is used to parse a string and returns a length value.
Syntax:
length = str.to_l
Arguments:
Return Value:
length - a length value in current units if successful
Comments:
Example:
teststring = "3.2m" begin len = teststring.to_l rescue UI.messagebox $!.message end if (len) UI.messagebox len else UI.messagebox "Failure" end