Trim Function

   
Trim Function

Class

Microsoft.VisualBasic.Strings

Syntax

 Trim(   str   ) 
str (required; String)

Any string expression

Return Value

String

Description

Removes both leading and trailing spaces from a given string

Rules at a Glance

If string is Nothing , the Trim function returns Nothing .

Programming Tips and Gotchas

Trim is equivalent to calling both the RTrim and LTrim functions.

VB.NET/VB 6 Differences

In VB 6, the function's single named argument is string . In VB.NET, its single named argument is str .

See Also

LTrim Function, RTrim Function

   


VB.Net Language in a Nutshell
VB.NET Language in a Nutshell
ISBN: B00006L54Q
EAN: N/A
Year: 2002
Pages: 503

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net