求一字符串中是否包含另一字符串的函数

来源:百度文库 编辑:神马文学网 时间:2024/10/04 05:33:27

vb中有个函数instr(),pb中如何办?求一字符串中是否包含另一字符串的函数相关解决方法:1、
求一字符串中是否包含另一字符串的函数推荐解答: 
Description 
Finds one string within another string.
Syntax 
Pos ( string1, string2 {, start } )
Argument Description
string1 The string in which you want to find string2
string2 The string you want to find in string1
start 
(optional) A long indicating where the search will begin in string1. The default is 1
Return value 
Long. Returns a long whose value is the starting position of the first occurrence of 

string2 in string1 after the position specified in start. If string2 is not found in string1 

or if start is not within string1, Pos returns 0. If any argument’s value is NULL, Pos returns NULL.
Usage 
The Pos function is case sensitive2、
求一字符串中是否包含另一字符串的函数推荐解答: 
用pos函数。
If pos(str1,str2)>0 str1中包含str2
否则<=03、
yes
用pos函数,请参考帮助!4、
使用pos函数,挺好用的,可以找到包含本人们经常使用