Difference between revisions of "Str.right"

From OpenEUO
Jump to: navigation, search
m (Created page with "== Calling Pattern == Call local r = sl.str.right(a,n) Args a is a string Results r is a string == Usage Example == local s = sl.str local r = s.right('Get the right side...")
 
m
 
Line 28: Line 28:
 
* [[str|string table]]
 
* [[str|string table]]
  
* [[str.right]]
+
* [[str.left]]
 +
 
 +
* [[str.mid]]
  
 
* [[str.split]]
 
* [[str.split]]
  
 
* [http://www.easyuo.com/openeuo/wiki/index.php/Documentation#String_Functions Lua String Functions]
 
* [http://www.easyuo.com/openeuo/wiki/index.php/Documentation#String_Functions Lua String Functions]

Latest revision as of 18:16, 11 November 2010

Calling Pattern

Call

local r = sl.str.right(a,n)

Args

a is a string

Results

r is a string


Usage Example

local s = sl.str
local r = s.right('Get the right side of a string.',12)
print(r)
--> of a string.

Description

Right returns the rightmost n characters of string a.

Upon Error

Right fails silently. If right receives inappropriate arguments then a '' (empty string) is returned.

See Also