ÄúµÄλÖãºÑ°ÃÎÍøÊ×Ò³£¾±à³ÌÀÖÔ°£¾VBScript£¾VBScript


objects constants operators statements functions properties methods






FUNCTION:  Left( )

Left(String, Length)

The Left function returns the left portion of the designated string for a designated length.


There are two mandatory arguments.

String

The String argument is the name of the string you wish to truncate.


Length

The Length argument is the number of characters (including blanks) you wish to save counting from the left side towards the right side of the string.

Code:
<% =Left("abcde fghij klmno pqrst uvwxyz", 13) %>

Output:
abcde fghij k