
3个回答
展开全部
'trim()是去除字符串头或尾部的空格,但不包含中间的空格。如:
Private Sub Form_Click()
dim str1 as string
dim str2 as string
str1 = " hello world "
str2 = trim(str1)
print str2
End Sub
'输出结果是"hello world"
Private Sub Form_Click()
dim str1 as string
dim str2 as string
str1 = " hello world "
str2 = trim(str1)
print str2
End Sub
'输出结果是"hello world"
展开全部
删除字串符的空格。如
dim word as string=" abc"
trim(word)
word="abc"
dim word as string=" abc"
trim(word)
word="abc"
展开全部
Trim()
FUNCTION: 去掉字符串左右的空格.
SYNTAX: Trim(string)
ARGUMENTS: string is any valid string expression.
EXAMPLE: <%
strTest = " This is a test!! "
response.write Trim(strTest)
%>
RESULT: This is a test!!
FUNCTION: 去掉字符串左右的空格.
SYNTAX: Trim(string)
ARGUMENTS: string is any valid string expression.
EXAMPLE: <%
strTest = " This is a test!! "
response.write Trim(strTest)
%>
RESULT: This is a test!!
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询