登海种业股票走势:VB得到字符串长度的代码?

来源:百度文库 编辑:杭州交通信息网 时间:2024/04/30 03:07:40
那个函数名是什么?就是要得到字符串长度的代码名。

len()

长度变量=Len(字符串)

如果是一个变数的话,可以用以下的方法计算
-------------------------------------------

Dim Name As String = "Mary"

MsgBox("The length is " & Name.Length) ' The length is 4

用len()
参数len(string)

。LENTH

Len()