StartWith
返回一个逻辑值,用来判断字符串是否以给定的子字符串开头。
语法:
StartWith(Value)
Value:给定的子字符串,判断是否以该子字符串开头。
示例:
Dim Country As String ="中华人民共和国"Dim Val1 As BooleanDim Val2 As BooleanVal1 = Country.StartsWith("中华")Val2 = Country.StartsWith("中国")Output.Show("Val1: " & Val1)Output.Show("Val2: " & Val2)
在命令窗口执行后,会显示:Val1: TrueVal2: False
该帮助中
语法:StartWith(Value) 是不是 StartsWith?