Sideway BICK BlogSideway BICK BLOG from Sideway

A Sideway to Sideway Home

Link:http://output.to/sideway/default.asp?qno=180300019

Script, Scripting Language, VBScript elements, Server-Side VBScript Function InStr, InStrB, InStrRev, StrComp Function

VBScript String Functions

Functions for manipulating string expression.

InStr Function

last updated 9/19/2017

Create a number from a given string1 by getting the position of the first occurrence of a specified string2 through searching from the specified searching position start towards the end of the given string1 according to the specified compare setting.

Syntax

InStr([start, ]string1, string2[, compare])

Argument

startOptional. Any valid numeric expression which is used to set the start searching position of the search. The first character position is position 1. If start argument is omitted, 1 is used which means that the search begins at the first character position. If compare argument is specified, a start argument is required.string1Required. Any valid string expression which is the string being searched.string2Required. Any valid string expression which is the string searched for.compareOptional setting. A constant that is used to indicate the kind of comparison used when evaluating substrings. If compare argument is omitted, 0 is used and a binary comparison is performed. If compare argument is specified, the start argument is required.

Settings

compare argument

vbConstantValueConstantvbBinaryCompare0Perform a binary comparison.vbTextCompare1Perform a textual comparison.

Returns

Returns a Variant of the Long data subtype containing a number obtained from a given string1 by getting the position of the first occurrence of a specified string2 through searching from the specified searching position start towards the end of the given string1 according to the specified compare setting.

Returns of InStr function:

ReturnDescription0string2 not found in string1 from start positioninteger character postion of Long data subtypefirst string2 found in string1 from start position

Typical Returns of InStr function:

startstring1, string2comparereturn value<1Any StringAny compareRun-time ErrorNil≡start=1String∉{Null,Empty,""}Nil≡compare=0 or compare∈{0,1}string2 not found in string1: 0;
string2 found in string1: the first integer character postion of Long data subtype
1≤start≤Len(string1)String∉{Null,Empty,""}Nil≡compare=0 or compare∈{0,1}string2 not found in string1 from start position: 0;
string2 found in string1 from start position: the first integer character postion of Long data subtype
>Len(string1)string1≠NullNil≡compare=0 or compare∈{0,1}0

Special returns of InStr function:

startstring1string2comparereturn valueNilNullNullNilNullNilNullEmptyNilNullNilNull""NilNullNilEmptyNullNilNullNilEmptyEmptyNil0NilEmpty""Nil0Nil""NullNilNullNil""EmptyNil0Nil""""Nil0Nil"" or EmptyString∉{"",Empty}Nil0NilString∉{"",Empty}"" or EmptyNil1<1String∉{"",Empty}"" or EmptyNilRun-time Error1≤start≤Len(string1)String∉{"",Empty}"" or EmptyNilstart>Len(string1)String∉{"",Empty}"" or EmptyNil0<1Any string1Any string2NilRun-time Error>Len(string1)Any StringAny StringNil0

Remarks

  • InStr function with 2 arguments is always elaborated as InStr(string1, string2).
  • InStr function with 3 arguments is always elaborated as InStr(start, string1, string2).
  • If compare argument setting is used, InStr function with 4 arguments, InStr(string1, string2, start, compare) is used.
  • The start argument must be numeric expression which is greater than or equal to 1 and is equal to Round(start).
  • The default value of start argument is 1.
  • If start argument less than 1, InStr function returns run-time error.
  • If start argument great than the length of string1, InStr function returns 0.
  • The compare argument setting must be number value 0, or 1 and is equal to Round(compare).
  • The default value of compare argument is 0.
  • If the setting of compare argument is other than 0, 1, InStr function returns run-time error.
  • If string1 and/or string2 is Null, InStr function returns Null.
  • If string1 is zeor-length string, InStr function returns 0.
  • If string2 is zeor-length string, InStr function returns start.
  • The InStrB function is used for manipulating byte data of a string expression, position returned is in terms of number of bytes.

Requirement

1

InStrB Function

last updated 9/19/2017

Create a number from a given string string1 by getting the first byte position of the first occurrence of a specified string string2 through searching from the specified searching position byte start towards the end of the given string string1 without consider the specified compare setting.

Syntax

InStrB([start, ]string1, string2[, compare])

Argument

startOptional. Any valid numeric expression which is used to set the start searching byte position of the search. The first byte position of first character is position 1. If start argument is omitted, 1 is used which means that the search begins at the first byte position of first character. However, the searching is still carried out character by character. A start speicified to the second byte of a DBCS character will casuse the searching to start on next DBCS character. If compare argument is specified, a start argument is required.string1Required. Any valid string expression which is the string being searched.string2Required. Any valid string expression which is the string searched for.compareOptional setting. A constant that is used to indicate the kind of comparison used when evaluating substrings. If compare argument is omitted, 0 is used and a binary comparison is performed. If compare argument is specified, the start argument is required. However, the setting doesnot affect the comparison for InStrB function, since InStrB function only uses binary comparison for byte comparison.

Settings

compare argument

vbConstantValueConstantvbBinaryCompare0Perform a binary comparison.vbTextCompare1Perform a textual comparison.

Returns

Returns a Variant of the Long data subtype containing a number obtaned from a given string string1 by getting the first byte position of the first occurrence of a specified string string2 through searching from the specified searching position byte start towards the end of the given string string1 without consider the specified compare setting.

Returns of InStrB function:

ReturnDescription0string2 not found in string1 from start positioninteger first byte postion of Long data subtypefirst string2 found in string1 from start position

Typical Returns of InStrB function:

startstring1, string2comparereturn value<1Any StringAny compareRun-time ErrorNil≡start=1String∉{Null,Empty,""}Nil≡compare=0 or compare∈{0,1}string2 not found in string1: 0;
string2 found in string1: the first integer byte postion of Long data subtype
1≤start≤LenB(string1)String∉{Null,Empty,""}Nil≡compare=0 or compare∈{0,1}string2 not found in string1 from start position: 0;
string2 found in string1 from start position: the first integer byte postion of Long data subtype
>LenB(string1)string1≠NullNil≡compare=0 or compare∈{0,1}0

Special returns of InStrB function:

startstring1string2comparereturn valueNilNullNullNilNullNilNullEmptyNilNullNilNull""NilNullNilEmptyNullNilNullNilEmptyEmptyNil0NilEmpty""Nil0Nil""NullNilNullNil""EmptyNil0Nil""""Nil0Nil"" or EmptyString∉{"",Empty}Nil0NilString∉{"",Empty}"" or EmptyNil1<1String∉{"",Empty}"" or EmptyNilRun-time Error1≤start≤LenB(string1)String∉{"",Empty}"" or EmptyNilstart>LenB(string1)String∉{"",Empty}"" or EmptyNil0<1Any string1Any string2NilRun-time Error>LenB(string1)Any StringAny StringNil0

Remarks

  • InStrB function with 2 arguments is always elaborated as InStrB(string1, string2).
  • InStrB function with 3 arguments is always elaborated as InStrB(start, string1, string2).
  • If compare argument setting is used, InStrB function with 4 arguments, InStrB(string1, string2, start, compare) is used.
  • The start argument must be numeric expression which is greater than or equal to 1 and is equal to Round(start).
  • The default value of start argument is 1.
  • If start argument less than 1, InStrB function returns run-time error.
  • If start argument great than the byte length of string1, InStrB function returns 0.
  • The compare argument setting must be number value 0, or 1 and is equal to Round(compare).
  • The default value of compare argument is 0.
  • If the setting of compare argument is other than 0, 1, InStrB function returns run-time error.
  • However, the setting does not affect the comparison for InStrB function, since InStrB function only uses binary comparison for byte comparison.
  • If string1 and/or string2 is Null, InStrB function returns Null.
  • If string1 is zeor-length string, InStrB function returns 0.
  • If string2 is zeor-length string, InStrB function returns start.
  • The InStrB function is used for manipulating byte data of a string expression, position returned is in terms of number of bytes.
  • However, the behavior of VBScript functions such as MidB, ChrB, LeftB, LenB, ChrB and AscB depends on the byte ordering of the hardware platform, and the number of bytes used to represent Unicode characters in the system software. The functions may produce different results on different operating systems.

Requirement

1

Examples

Examples of InStr functions

ASP VbScript Command:
<script runat="server" language="VBScript">
Function cmda1:select case x:case 2:cmda1="InStr(str1,str2)":Case 3:cmda1="InStr(fir,str1,str2)":Case 4:cmda1="InStr(fir,str1,str2,cmp)":End Select:End Function
Function cmda2:select case x:case 2:cmda2="InStrB(str1,str2)":Case 3:cmda2="InStrB(fir,str1,str2)":Case 4:cmda2="InStrB(fir,str1,str2,cmp)":End Select:End Function
Dim vars,fir,str1,str2,cmp,x,cmda,var:var=0
cmda=array("str1","str2","eval(""cmda1"")","Eval(cmda1)","eval(""cmda2"")","Eval(cmda2)")
Dim ucnt,tmp,i:ucnt=UBound(cmda):If var=1 Then:tmp="":Else:tmp="<b>vars</b>":End If:For i=0 to ucnt:tmp=tmp&"<b>"&rmv_ctrl(cmda(i))&", TypeName</b>":Next:Response.Write "Results on Microsoft Windows 8.1 Pro x64, Microsoft-IIS/8.5, VBScript Version 5.8 of page /internet/users/sideblog/default.asp<br />"&"<i>"&tmp&"</i>"
Function dsp_x:Dim tmp_a,tmp_b,i:If varx=0  Then:Execute vars:End If:If var=1 Then:tmp_a="":Else:tmp_a=rmv_ctrl(vars):End If:For i=0 to ucnt:tmp_b=cmd_b(cmda(i)):if i/2=fix(i/2) Then:tmp_b="<b>"&tmp_b&"</b>":End If:tmp_a=tmp_a&tmp_b:Next:Response.Write "<i>"&tmp_a&"</i>":End Function
Function rmv_ctrl(blk_str):Select Case blk_str:Case chr(0):blk_str="NUL":Case chr(1):blk_str="SOH":Case chr(2):blk_str="STX":Case chr(3):blk_str="ETX":Case chr(4):blk_str="EOT":Case chr(5):blk_str="ENQ":Case chr(6):blk_str="ACK":Case chr(7):blk_str="BEL":Case chr(8):blk_str="BS":Case chr(9):blk_str="HT":Case chr(10):blk_str="LF":Case chr(11):blk_str="VT":Case chr(12):blk_str="FF":Case chr(13):blk_str="CR":Case chr(14):blk_str="SO":Case chr(15):blk_str="SI":Case chr(16):blk_str="DLE":Case chr(17):blk_str="DC1":Case chr(18):blk_str="DC2":Case chr(19):blk_str="DC3":Case chr(20):blk_str="DC4":Case chr(21):blk_str="NAK":Case chr(22):blk_str="SYN":Case chr(23):blk_str="ETB":Case chr(24):blk_str="CAN":Case chr(25):blk_str="EM":Case chr(26):blk_str="SUB":Case chr(27):blk_str="ESC":Case chr(28):blk_str="FS":Case chr(29):blk_str="GS":Case chr(30):blk_str="RS":Case chr(31):blk_str="US":Case chr(127):blk_str="DEL":End Select:rmv_ctrl=blk_str:If IsNull(blk_str) OR IsEmpty(Blk_str) OR blk_str="" OR IsNumeric(Blk_str) Then:Else:rmv_ctrl=Replace(Replace(Replace(Replace(Replace(blk_str,"&","&amp;"),"  "," &nbsp;"),"""","&quot;"),"<","&lt;"),">","&gt;"): End If :End Function
Function cmd_b(blk_str):cmd_b="["&cmd_x(blk_str)&"], "&cmd_x("TypeName("&blk_str&")"):End Function
Function cmd_x(blk_str):On Error Resume Next:Dim xans, tmp:xans="":tmp="":execute "xans="&blk_str:If Err.Number <> 0  Then:xans=cmd_x("TypeName("&blk_str&")"):Select Case xans:Case 9::Case Else:xans="error":End Select:End If:If IsArray(xans)=False Then:cmd_x=rmv_ctrl(xans): Else:tmp=lst_arry(xans):cmd_x=trim(tmp):End If:End Function
Function lst_arry(blk_str):Dim tmp,i,q:q="""":tmp="":For i=0 to UBound(blk_str):if VarType(blk_str(i))>1 And VarType(blk_str(i))<6 Then:q="'":End If:tmp=tmp&" "&q&rmv_ctrl(blk_str(i))&q:Next:lst_arry=trim(tmp):End Function

vars="str1=Null:str2=Null":x=2:dsp_x
vars="str1=Null:str2=Empty":dsp_x
vars="str1=Null:str2=""""":dsp_x
vars="str1=Empty:str2=Null":dsp_x
vars="str1=Empty:str2=Empty":dsp_x
vars="str1=Empty:str2=""""":dsp_x
vars="str1="""":str2=Null":dsp_x
vars="str1="""":str2=Empty":dsp_x
vars="str1="""":str2=""""":dsp_x
vars="str1="""":str2=""a""":dsp_x
vars="str1=Empty:str2=""a""":dsp_x
vars="str1=""asdf"":str2=""""":dsp_x
vars="str1=""asdf"":str2=Empty":dsp_x
vars="str1=""asdf"":str2=""a""":dsp_x
vars="str1=""asdf"":str2=""s""":dsp_x
vars="str1=""asASasAS"":str2=""sA""":dsp_x
vars="str1=Unescape(""%53%73%53""):str2=""S""":dsp_x
vars="str1=Unescape(""%53%73%53""):str2=""s""":dsp_x
vars="str1=Unescape(""%u0153%73%53""):str2=""S""":dsp_x
vars="str1=Unescape(""%u0153%73%53""):str2=""s""":dsp_x
vars="fir=1:str1=""asdf"":str2=""""":x=3:dsp_x
vars="fir=2:str1=""asdf"":str2=""""":dsp_x
vars="fir=3:str1=""asdf"":str2=""""":dsp_x
vars="fir=4:str1=""asdf"":str2=Empty":dsp_x
vars="fir=5:str1=""asdf"":str2=""""":dsp_x
vars="fir=6:str1=""asdf"":str2=Empty":dsp_x
vars="fir=8:str1=""asdf"":str2=Empty":dsp_x
vars="fir=10:str1=""asdf"":str2=Empty":dsp_x
vars="fir=1:str1=""asASasAS"":str2=""sA""":dsp_x
vars="fir=4:str1=""asASasAS"":str2=""sA""":dsp_x
vars="fir=7:str1=""asASasAS"":str2=""sA""":dsp_x
vars="fir=2:str1=Unescape(""%53%73%53""):str2=""S""":dsp_x
vars="fir=2:str1=Unescape(""%53%73%53""):str2=""s""":dsp_x
vars="fir=2:str1=Unescape(""%u0153%73%53""):str2=""S""":dsp_x
vars="fir=2:str1=Unescape(""%u0153%73%53""):str2=""s""":dsp_x
vars="fir=3:str1=Unescape(""%53%73%53""):str2=""S""":dsp_x
vars="fir=3:str1=Unescape(""%53%73%53""):str2=""s""":dsp_x
vars="fir=3:str1=Unescape(""%u0153%73%53""):str2=""S""":dsp_x
vars="fir=3:str1=Unescape(""%u0153%73%53""):str2=""s""":dsp_x
vars="fir=4:str1=Unescape(""%53%73%53""):str2=""S""":dsp_x
vars="fir=4:str1=Unescape(""%53%73%53""):str2=""s""":dsp_x
vars="fir=4:str1=Unescape(""%u0153%73%53""):str2=""S""":dsp_x
vars="fir=4:str1=Unescape(""%u0153%73%53""):str2=""s""":dsp_x
vars="fir=2:str1=""asASasAS"":str2=""sA"":cmp=1":x=4:dsp_x
vars="fir=4:str1=""asASasAS"":str2=""sA"":cmp=1":dsp_x
vars="fir=7:str1=""asASasAS"":str2=""sA"":cmp=1":dsp_x
vars="fir=1:str1=Unescape(""%53%73%53""):str2=""S"":cmp=1":dsp_x
vars="fir=1:str1=Unescape(""%53%73%53""):str2=""s"":cmp=1":dsp_x
vars="fir=1:str1=Unescape(""%u0153%73%53""):str2=""S"":cmp=1":dsp_x
vars="fir=1:str1=Unescape(""%u0153%73%53""):str2=""s"":cmp=1":dsp_x
</script>
HTML Web Page In-line Output:
Results on Microsoft Windows 8.1 Pro x64, Microsoft-IIS/8.5, VBScript Version 5.8 of page /internet/users/sideblog/default.asp
varsstr1, TypeNamestr2, TypeNameeval("cmda1"), TypeNameEval(cmda1), TypeNameeval("cmda2"), TypeNameEval(cmda2), TypeNamestr1=Null:str2=Null[], Null[], Null[InStr(str1,str2)], String[], Null[InStrB(str1,str2)], String[], Nullstr1=Null:str2=Empty[], Null[], Empty[InStr(str1,str2)], String[], Null[InStrB(str1,str2)], String[], Nullstr1=Null:str2=""[], Null[], String[InStr(str1,str2)], String[], Null[InStrB(str1,str2)], String[], Nullstr1=Empty:str2=Null[], Empty[], Null[InStr(str1,str2)], String[], Null[InStrB(str1,str2)], String[], Nullstr1=Empty:str2=Empty[], Empty[], Empty[InStr(str1,str2)], String[0], Long[InStrB(str1,str2)], String[0], Longstr1=Empty:str2=""[], Empty[], String[InStr(str1,str2)], String[0], Long[InStrB(str1,str2)], String[0], Longstr1="":str2=Null[], String[], Null[InStr(str1,str2)], String[], Null[InStrB(str1,str2)], String[], Nullstr1="":str2=Empty[], String[], Empty[InStr(str1,str2)], String[0], Long[InStrB(str1,str2)], String[0], Longstr1="":str2=""[], String[], String[InStr(str1,str2)], String[0], Long[InStrB(str1,str2)], String[0], Longstr1="":str2="a"[], String[a], String[InStr(str1,str2)], String[0], Long[InStrB(str1,str2)], String[0], Longstr1=Empty:str2="a"[], Empty[a], String[InStr(str1,str2)], String[0], Long[InStrB(str1,str2)], String[0], Longstr1="asdf":str2=""[asdf], String[], String[InStr(str1,str2)], String[1], Long[InStrB(str1,str2)], String[1], Longstr1="asdf":str2=Empty[asdf], String[], Empty[InStr(str1,str2)], String[1], Long[InStrB(str1,str2)], String[1], Longstr1="asdf":str2="a"[asdf], String[a], String[InStr(str1,str2)], String[1], Long[InStrB(str1,str2)], String[1], Longstr1="asdf":str2="s"[asdf], String[s], String[InStr(str1,str2)], String[2], Long[InStrB(str1,str2)], String[3], Longstr1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStr(str1,str2)], String[2], Long[InStrB(str1,str2)], String[3], Longstr1=Unescape("%53%73%53"):str2="S"[SsS], String[S], String[InStr(str1,str2)], String[1], Long[InStrB(str1,str2)], String[1], Longstr1=Unescape("%53%73%53"):str2="s"[SsS], String[s], String[InStr(str1,str2)], String[2], Long[InStrB(str1,str2)], String[3], Longstr1=Unescape("%u0153%73%53"):str2="S"[œsS], String[S], String[InStr(str1,str2)], String[3], Long[InStrB(str1,str2)], String[5], Longstr1=Unescape("%u0153%73%53"):str2="s"[œsS], String[s], String[InStr(str1,str2)], String[2], Long[InStrB(str1,str2)], String[3], Longfir=1:str1="asdf":str2=""[asdf], String[], String[InStr(fir,str1,str2)], String[1], Long[InStrB(fir,str1,str2)], String[1], Longfir=2:str1="asdf":str2=""[asdf], String[], String[InStr(fir,str1,str2)], String[2], Long[InStrB(fir,str1,str2)], String[2], Longfir=3:str1="asdf":str2=""[asdf], String[], String[InStr(fir,str1,str2)], String[3], Long[InStrB(fir,str1,str2)], String[3], Longfir=4:str1="asdf":str2=Empty[asdf], String[], Empty[InStr(fir,str1,str2)], String[4], Long[InStrB(fir,str1,str2)], String[4], Longfir=5:str1="asdf":str2=""[asdf], String[], String[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[5], Longfir=6:str1="asdf":str2=Empty[asdf], String[], Empty[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[6], Longfir=8:str1="asdf":str2=Empty[asdf], String[], Empty[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[8], Longfir=10:str1="asdf":str2=Empty[asdf], String[], Empty[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[0], Longfir=1:str1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStr(fir,str1,str2)], String[2], Long[InStrB(fir,str1,str2)], String[3], Longfir=4:str1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStr(fir,str1,str2)], String[6], Long[InStrB(fir,str1,str2)], String[11], Longfir=7:str1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[11], Longfir=2:str1=Unescape("%53%73%53"):str2="S"[SsS], String[S], String[InStr(fir,str1,str2)], String[3], Long[InStrB(fir,str1,str2)], String[5], Longfir=2:str1=Unescape("%53%73%53"):str2="s"[SsS], String[s], String[InStr(fir,str1,str2)], String[2], Long[InStrB(fir,str1,str2)], String[3], Longfir=2:str1=Unescape("%u0153%73%53"):str2="S"[œsS], String[S], String[InStr(fir,str1,str2)], String[3], Long[InStrB(fir,str1,str2)], String[5], Longfir=2:str1=Unescape("%u0153%73%53"):str2="s"[œsS], String[s], String[InStr(fir,str1,str2)], String[2], Long[InStrB(fir,str1,str2)], String[3], Longfir=3:str1=Unescape("%53%73%53"):str2="S"[SsS], String[S], String[InStr(fir,str1,str2)], String[3], Long[InStrB(fir,str1,str2)], String[5], Longfir=3:str1=Unescape("%53%73%53"):str2="s"[SsS], String[s], String[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[3], Longfir=3:str1=Unescape("%u0153%73%53"):str2="S"[œsS], String[S], String[InStr(fir,str1,str2)], String[3], Long[InStrB(fir,str1,str2)], String[5], Longfir=3:str1=Unescape("%u0153%73%53"):str2="s"[œsS], String[s], String[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[3], Longfir=4:str1=Unescape("%53%73%53"):str2="S"[SsS], String[S], String[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[5], Longfir=4:str1=Unescape("%53%73%53"):str2="s"[SsS], String[s], String[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[0], Longfir=4:str1=Unescape("%u0153%73%53"):str2="S"[œsS], String[S], String[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[5], Longfir=4:str1=Unescape("%u0153%73%53"):str2="s"[œsS], String[s], String[InStr(fir,str1,str2)], String[0], Long[InStrB(fir,str1,str2)], String[0], Longfir=2:str1="asASasAS":str2="sA":cmp=1[asASasAS], String[sA], String[InStr(fir,str1,str2,cmp)], String[2], Long[InStrB(fir,str1,str2,cmp)], String[3], Longfir=4:str1="asASasAS":str2="sA":cmp=1[asASasAS], String[sA], String[InStr(fir,str1,str2,cmp)], String[4], Long[InStrB(fir,str1,str2,cmp)], String[11], Longfir=7:str1="asASasAS":str2="sA":cmp=1[asASasAS], String[sA], String[InStr(fir,str1,str2,cmp)], String[0], Long[InStrB(fir,str1,str2,cmp)], String[11], Longfir=1:str1=Unescape("%53%73%53"):str2="S":cmp=1[SsS], String[S], String[InStr(fir,str1,str2,cmp)], String[1], Long[InStrB(fir,str1,str2,cmp)], String[1], Longfir=1:str1=Unescape("%53%73%53"):str2="s":cmp=1[SsS], String[s], String[InStr(fir,str1,str2,cmp)], String[1], Long[InStrB(fir,str1,str2,cmp)], String[3], Longfir=1:str1=Unescape("%u0153%73%53"):str2="S":cmp=1[œsS], String[S], String[InStr(fir,str1,str2,cmp)], String[2], Long[InStrB(fir,str1,str2,cmp)], String[5], Longfir=1:str1=Unescape("%u0153%73%53"):str2="s":cmp=1[œsS], String[s], String[InStr(fir,str1,str2,cmp)], String[2], Long[InStrB(fir,str1,str2,cmp)], String[3], Long

InStrRev Function

last updated 9/19/2017

Get the position of the first occurrence of a specified string within another given string by searching from the specified start searching position, default is at the end of string, towards the start of the given string.

Syntax

InStrRev(string1, string2[, start[, compare]])

Argument

string1Required. Any valid string expression which is the string being searched.string2Required. Any valid string expression which is the string searched for.startOptional. Any valid numeric expression which is used to set the start searching position of the search. The first character position is position 1. If start argument is omitted, -1 is used which means that the search begins at the end character position.compareOptional setting. A constant that is used to indicate the kind of comparison used when evaluating substrings. If compare argument is omitted, 0 is used and a binary comparison is performed.

Settings

compare argument

vbConstantValueConstantvbBinaryCompare0Perform a binary comparison.vbTextCompare1Perform a textual comparison.

Returns

Returns a Variant of the Long data subtype containing the position of the first occurrence of a specified string within another given string by searching from the specified start searching position, default is at the end of a given string, towards the start of the given string.

Returns of InStrRev function:

ReturnDescription0string2 not found in string1 from start positioninteger postion of Long data subtypefirst string2 found in string1 from start position

Typical Returns of InStrRev function:

startstring1, string2comparereturn valuestart<-1, or start=0Any StringAny compareRun-time ErrorNil≡start=-1, or start=-1String∉{Null,Empty,""}Nil≡compare=0 or compare∈{0,1}string2 not found in string1: 0;
string2 found in string1: the first integer postion of Long data subtype
1≤start≤Len(string1)String∉{Null,Empty,""}Nil≡compare=0 or compare∈{0,1}string2 not found in string1 from start position: 0;
string2 found in string1 from start position: the first integer postion of Long data subtype
start>Len(string1)string1≠NullNil≡compare=0 or compare∈{0,1}0

Special returns of InStrRev function:

startstring1string2comparereturn valueNilNullNullNilRun-time ErrorNilNullEmptyNilRun-time ErrorNilNull""NilRun-time ErrorNilEmptyNullNilRun-time ErrorNilEmptyEmptyNil0NilEmpty""Nil0Nil""NullNilRun-time ErrorNil""EmptyNil0Nil""""Nil0Nil"" or EmptyString∉{"",Empty}Nil0Nil or start=-1String∉{"",Empty}"" or EmptyNilLen(string1)<-1, or =0String∉{"",Empty}"" or EmptyNilRun-time Error1≤start≤Len(string1)String∉{"",Empty}"" or EmptyNilstart>Len(string1)String∉{"",Empty}"" or EmptyNil0<-1, or =0Any string1Any string2NilRun-time Error>Len(string1)Any StringAny StringNil0

Remarks

  • InStrRev function with 2 arguments is always elaborated as InStrRev(string1, string2).
  • InStrRev function with 3 arguments is always elaborated as InStrRev(string1, string2, start).
  • InStrRev function with 4 arguments is always elaborated as InStrRev(string1, string2, start, compare) is used.
  • The syntax for the InStrRev function is not the same as the syntax for the InStrRev function.
  • The start argument must be numeric expression which is greater than or equal to 1, or equal to -1 and is equal to Round(start).
  • The default value of start argument is -1 which means that the search begins at the end character position.
  • If start argument less than -1, or equal to zero, InStrRev function returns run-time error.
  • If start argument great than the length of string1, InStrRev function returns 0.
  • The compare argument setting must be number value 0, or 1 and is equal to Round(compare).
  • The default value of compare argument is 0.
  • If the setting of compare argument is other than 0, 1, InStrRev function returns run-time error.
  • If string1 and/or string2 is Null, InStrRev function returns Run-time Error.
  • If string1 is zeor-length string, InStrRev function returns 0.
  • If string2 is zeor-length string, InStrRev function returns start when valid start argument is given and is not equal -1, and Len(string1) is returned when start argument is omitted or equal to -1
  • The InStrB function is used for manipulating byte data of a string expression, position returned is in terms of number of bytes.

Requirement

2

Examples

Examples of InStrRev functions

ASP VbScript Command:
<script runat="server" language="VBScript">
Function cmda1:cmda1="InStrRev(str1,str2,fir,cmp)":cmda1=Left(cmda1,Len(cmda1)-4*(4-x)-1)&")":End Function
Dim vars,fir,str1,str2,cmp,x,cmda,var:var=0
cmda=array("str1","str2","(eval(""cmda1""))","Eval(cmda1)")
Dim ucnt,tmp,i:ucnt=UBound(cmda):If var=1 Then:tmp="":Else:tmp="<b>vars</b>":End If:For i=0 to ucnt:tmp=tmp&"<b>"&rmv_ctrl(cmda(i))&", TypeName</b>":Next:Response.Write "Results on Microsoft Windows 8.1 Pro x64, Microsoft-IIS/8.5, VBScript Version 5.8 of page /internet/users/sideblog/default.asp<br />"&"<i>"&tmp&"</i>"
Function dsp_x:Dim tmp_a,tmp_b,i:If varx=0  Then:Execute vars:End If:If var=1 Then:tmp_a="":Else:tmp_a=rmv_ctrl(vars):End If:For i=0 to ucnt:tmp_b=cmd_b(cmda(i)):if i/2=fix(i/2) Then:tmp_b="<b>"&tmp_b&"</b>":End If:tmp_a=tmp_a&tmp_b:Next:Response.Write "<i>"&tmp_a&"</i>":End Function
Function rmv_ctrl(blk_str):Select Case blk_str:Case chr(0):blk_str="NUL":Case chr(1):blk_str="SOH":Case chr(2):blk_str="STX":Case chr(3):blk_str="ETX":Case chr(4):blk_str="EOT":Case chr(5):blk_str="ENQ":Case chr(6):blk_str="ACK":Case chr(7):blk_str="BEL":Case chr(8):blk_str="BS":Case chr(9):blk_str="HT":Case chr(10):blk_str="LF":Case chr(11):blk_str="VT":Case chr(12):blk_str="FF":Case chr(13):blk_str="CR":Case chr(14):blk_str="SO":Case chr(15):blk_str="SI":Case chr(16):blk_str="DLE":Case chr(17):blk_str="DC1":Case chr(18):blk_str="DC2":Case chr(19):blk_str="DC3":Case chr(20):blk_str="DC4":Case chr(21):blk_str="NAK":Case chr(22):blk_str="SYN":Case chr(23):blk_str="ETB":Case chr(24):blk_str="CAN":Case chr(25):blk_str="EM":Case chr(26):blk_str="SUB":Case chr(27):blk_str="ESC":Case chr(28):blk_str="FS":Case chr(29):blk_str="GS":Case chr(30):blk_str="RS":Case chr(31):blk_str="US":Case chr(127):blk_str="DEL":End Select:rmv_ctrl=blk_str:If IsNull(blk_str) OR IsEmpty(Blk_str) OR blk_str="" OR IsNumeric(Blk_str) Then:Else:rmv_ctrl=Replace(Replace(Replace(Replace(Replace(blk_str,"&","&amp;"),"  "," &nbsp;"),"""","&quot;"),"<","&lt;"),">","&gt;"): End If :End Function
Function cmd_b(blk_str):cmd_b="["&cmd_x(blk_str)&"], "&cmd_x("TypeName("&blk_str&")"):End Function
Function cmd_x(blk_str):On Error Resume Next:Dim xans, tmp:xans="":tmp="":execute "xans="&blk_str:If Err.Number <> 0  Then:xans=cmd_x("TypeName("&blk_str&")"):Select Case xans:Case 9::Case Else:xans="error":End Select:End If:If IsArray(xans)=False Then:cmd_x=rmv_ctrl(xans): Else:tmp=lst_arry(xans):cmd_x=trim(tmp):End If:End Function
Function lst_arry(blk_str):Dim tmp,i,q:q="""":tmp="":For i=0 to UBound(blk_str):if VarType(blk_str(i))>1 And VarType(blk_str(i))<6 Then:q="'":End If:tmp=tmp&" "&q&rmv_ctrl(blk_str(i))&q:Next:lst_arry=trim(tmp):End Function

vars="str1=Empty:str2=Empty":x=2:dsp_x
vars="str1=Empty:str2=""""":dsp_x
vars="str1="""":str2=Empty":dsp_x
vars="str1="""":str2=""""":dsp_x
vars="str1="""":str2=""a""":dsp_x
vars="str1=Empty:str2=""a""":dsp_x
vars="str1=""asdf"":str2=""""":dsp_x
vars="str1=""asdf"":str2=Empty":dsp_x
vars="str1=""asdf"":str2=""a""":dsp_x
vars="str1=""asdf"":str2=""s""":dsp_x
vars="str1=""asASasAS"":str2=""sA""":dsp_x
vars="fir=-1:str1=""asdf"":str2=""""":x=3:dsp_x
vars="fir=1:str1=""asdf"":str2=""""":dsp_x
vars="fir=3:str1=""asdf"":str2=""""":dsp_x
vars="fir=5:str1=""asdf"":str2=""""":dsp_x
vars="fir=-1:str1=""asASasAS"":str2=""sA""":dsp_x
vars="fir=1:str1=""asASasAS"":str2=""sA""":dsp_x
vars="fir=5:str1=""asASasAS"":str2=""sA""":dsp_x
vars="fir=7:str1=""asASasAS"":str2=""sA""":dsp_x
vars="fir=-1:str1=""asASasAS"":str2=""sA"":cmp=1":x=4:dsp_x
vars="fir=1:str1=""asASasAS"":str2=""sA"":cmp=1":dsp_x
vars="fir=5:str1=""asASasAS"":str2=""sA"":cmp=1":dsp_x
vars="fir=7:str1=""asASasAS"":str2=""sA"":cmp=1":dsp_x
</script>
HTML Web Page In-line Output:
Results on Microsoft Windows 8.1 Pro x64, Microsoft-IIS/8.5, VBScript Version 5.8 of page /internet/users/sideblog/default.asp
varsstr1, TypeNamestr2, TypeName(eval("cmda1")), TypeNameEval(cmda1), TypeNamestr1=Empty:str2=Empty[], Empty[], Empty[InStrRev(str1,str2)], String[0], Longstr1=Empty:str2=""[], Empty[], String[InStrRev(str1,str2)], String[0], Longstr1="":str2=Empty[], String[], Empty[InStrRev(str1,str2)], String[0], Longstr1="":str2=""[], String[], String[InStrRev(str1,str2)], String[0], Longstr1="":str2="a"[], String[a], String[InStrRev(str1,str2)], String[0], Longstr1=Empty:str2="a"[], Empty[a], String[InStrRev(str1,str2)], String[0], Longstr1="asdf":str2=""[asdf], String[], String[InStrRev(str1,str2)], String[4], Longstr1="asdf":str2=Empty[asdf], String[], Empty[InStrRev(str1,str2)], String[4], Longstr1="asdf":str2="a"[asdf], String[a], String[InStrRev(str1,str2)], String[1], Longstr1="asdf":str2="s"[asdf], String[s], String[InStrRev(str1,str2)], String[2], Longstr1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStrRev(str1,str2)], String[6], Longfir=-1:str1="asdf":str2=""[asdf], String[], String[InStrRev(str1,str2,fir)], String[4], Longfir=1:str1="asdf":str2=""[asdf], String[], String[InStrRev(str1,str2,fir)], String[1], Longfir=3:str1="asdf":str2=""[asdf], String[], String[InStrRev(str1,str2,fir)], String[3], Longfir=5:str1="asdf":str2=""[asdf], String[], String[InStrRev(str1,str2,fir)], String[0], Longfir=-1:str1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStrRev(str1,str2,fir)], String[6], Longfir=1:str1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStrRev(str1,str2,fir)], String[0], Longfir=5:str1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStrRev(str1,str2,fir)], String[2], Longfir=7:str1="asASasAS":str2="sA"[asASasAS], String[sA], String[InStrRev(str1,str2,fir)], String[6], Longfir=-1:str1="asASasAS":str2="sA":cmp=1[asASasAS], String[sA], String[InStrRev(str1,str2,fir,cmp)], String[6], Longfir=1:str1="asASasAS":str2="sA":cmp=1[asASasAS], String[sA], String[InStrRev(str1,str2,fir,cmp)], String[0], Longfir=5:str1="asASasAS":str2="sA":cmp=1[asASasAS], String[sA], String[InStrRev(str1,str2,fir,cmp)], String[4], Longfir=7:str1="asASasAS":str2="sA":cmp=1[asASasAS], String[sA], String[InStrRev(str1,str2,fir,cmp)], String[6], Long

StrComp Function

last updated 9/21/2017

Create a value to indicate the result of comparison between given string1 and string2 according to the specified compare setting.

Syntax

StrComp(string1, string2[, compare])

Argument

string1Required. Any valid string expression which is the string being compared with.string2Required. Any valid string expression which is the string used to compare.compareOptional setting. A constant that is used to indicate the kind of comparison used when evaluating strings. If compare argument is omitted, 0 is used and a binary comparison is performed.

Settings

compare argument

vbConstantValueConstantvbBinaryCompare0Perform a binary comparison.vbTextCompare1Perform a textual comparison.

Returns

Returns a Variant of Integer data subtype containing a value indicating the result of comparison between given string1 and string2 according to the specified compare setting.

Return values of StrComp function

StrCompDescription-1string1 is less than string2.0string1 is equal to string2.1string1 is greater than string2.

Special Return of StrComp function

String1String2ReturnNullNullNullNullEmptyNullNull""NullEmptyNullNullEmptyEmpty0Empty""0""NullNull""Empty0""""0

Remarks

  • StrComp function returns the results of a string comparison.
  • The compare argument setting must be number value 0, or 1 and is equal to Round(compare).
  • The default value of compare argument is 0.
  • If the setting of compare argument is other than 0, 1, StrComp function returns run-time error.

Requirement

1

Examples

Examples of StrComp functions

ASP VbScript Command:
<script runat="server" language="VBScript">
Function cmda1:cmda1="StrComp(str1,str2,cmp)":cmda1=Left(cmda1,Len(cmda1)-4*(3-x)-1)&")":End Function
Dim vars,str1,str2,cmp,x,cmda,var::var=0
cmda=array("str1","str2","eval(""cmda1"")","Eval(cmda1)")
Dim ucnt,tmp,i:ucnt=UBound(cmda):If var=1 Then:tmp="":Else:tmp="<b>vars</b>":End If:For i=0 to ucnt:tmp=tmp&"<b>"&rmv_ctrl(cmda(i))&", TypeName</b>":Next:Response.Write "Results on Microsoft Windows 8.1 Pro x64, Microsoft-IIS/8.5, VBScript Version 5.8 of page /internet/users/sideblog/default.asp<br />"&"<i>"&tmp&"</i>"
Function dsp_x:Dim tmp_a,tmp_b,i:If varx=0  Then:Execute vars:End If:If var=1 Then:tmp_a="":Else:tmp_a=rmv_ctrl(vars):End If:For i=0 to ucnt:tmp_b=cmd_b(cmda(i)):if i/2=fix(i/2) Then:tmp_b="<b>"&tmp_b&"</b>":End If:tmp_a=tmp_a&tmp_b:Next:Response.Write "<i>"&tmp_a&"</i>":End Function
Function rmv_ctrl(blk_str):Select Case blk_str:Case chr(0):blk_str="NUL":Case chr(1):blk_str="SOH":Case chr(2):blk_str="STX":Case chr(3):blk_str="ETX":Case chr(4):blk_str="EOT":Case chr(5):blk_str="ENQ":Case chr(6):blk_str="ACK":Case chr(7):blk_str="BEL":Case chr(8):blk_str="BS":Case chr(9):blk_str="HT":Case chr(10):blk_str="LF":Case chr(11):blk_str="VT":Case chr(12):blk_str="FF":Case chr(13):blk_str="CR":Case chr(14):blk_str="SO":Case chr(15):blk_str="SI":Case chr(16):blk_str="DLE":Case chr(17):blk_str="DC1":Case chr(18):blk_str="DC2":Case chr(19):blk_str="DC3":Case chr(20):blk_str="DC4":Case chr(21):blk_str="NAK":Case chr(22):blk_str="SYN":Case chr(23):blk_str="ETB":Case chr(24):blk_str="CAN":Case chr(25):blk_str="EM":Case chr(26):blk_str="SUB":Case chr(27):blk_str="ESC":Case chr(28):blk_str="FS":Case chr(29):blk_str="GS":Case chr(30):blk_str="RS":Case chr(31):blk_str="US":Case chr(127):blk_str="DEL":End Select:rmv_ctrl=blk_str:If IsNull(blk_str) OR IsEmpty(Blk_str) OR blk_str="" OR IsNumeric(Blk_str) Then:Else:rmv_ctrl=Replace(Replace(Replace(Replace(Replace(blk_str,"&","&amp;"),"  "," &nbsp;"),"""","&quot;"),"<","&lt;"),">","&gt;"): End If :End Function
Function cmd_b(blk_str):cmd_b="["&cmd_x(blk_str)&"], "&cmd_x("TypeName("&blk_str&")"):End Function
Function cmd_x(blk_str):On Error Resume Next:Dim xans, tmp:xans="":tmp="":execute "xans="&blk_str:If Err.Number <> 0  Then:xans=cmd_x("TypeName("&blk_str&")"):Select Case xans:Case 9::Case Else:xans="error":End Select:End If:If IsArray(xans)=False Then:cmd_x=rmv_ctrl(xans): Else:tmp=lst_arry(xans):cmd_x=trim(tmp):End If:End Function
Function lst_arry(blk_str):Dim tmp,i,q:q="""":tmp="":For i=0 to UBound(blk_str):if VarType(blk_str(i))>1 And VarType(blk_str(i))<6 Then:q="'":End If:tmp=tmp&" "&q&rmv_ctrl(blk_str(i))&q:Next:lst_arry=trim(tmp):End Function

vars="str1=Null:str2=Null":x=2:dsp_x
vars="str1=Null:str2=Empty":dsp_x
vars="str1=Null:str2=""""":dsp_x
vars="str1=Empty:str2=Null":dsp_x
vars="str1=Empty:str2=Empty":dsp_x
vars="str1=Empty:str2=""""":dsp_x
vars="str1="""":str2=Null":dsp_x
vars="str1="""":str2=Empty":dsp_x
vars="str1="""":str2=""""":dsp_x
vars="str1="""":str2=""a""":dsp_x
vars="str1=Empty:str2=""a""":dsp_x
vars="str1=""a"":str2=""""":dsp_x
vars="str1=""a"":str2=Empty":dsp_x
vars="str1=""a"":str2=""a""":dsp_x
vars="str1=""a"":str2=""b""":dsp_x
vars="str1=""b"":str2=""a""":dsp_x
vars="str1=""b"":str2=""b""":dsp_x
vars="str1=""A"":str2=""A""":dsp_x
vars="str1=""A"":str2=""B""":dsp_x
vars="str1=""B"":str2=""A""":dsp_x
vars="str1=""B"":str2=""B""":dsp_x
vars="str1=""a"":str2=""A""":dsp_x
vars="str1=""a"":str2=""B""":dsp_x
vars="str1=""b"":str2=""A""":dsp_x
vars="str1=""b"":str2=""B""":dsp_x
vars="str1=""A"":str2=""a""":dsp_x
vars="str1=""B"":str2=""a""":dsp_x
vars="str1=""A"":str2=""b""":dsp_x
vars="str1=""B"":str2=""b""":dsp_x
vars="str1=""a"":str2=""a"":cmp=1":x=3:dsp_x
vars="str1=""a"":str2=""b"":cmp=1":dsp_x
vars="str1=""b"":str2=""a"":cmp=1":dsp_x
vars="str1=""b"":str2=""b"":cmp=1":dsp_x
vars="str1=""A"":str2=""A"":cmp=1":dsp_x
vars="str1=""A"":str2=""B"":cmp=1":dsp_x
vars="str1=""B"":str2=""A"":cmp=1":dsp_x
vars="str1=""B"":str2=""B"":cmp=1":dsp_x
vars="str1=""a"":str2=""A"":cmp=1":dsp_x
vars="str1=""a"":str2=""B"":cmp=1":dsp_x
vars="str1=""b"":str2=""A"":cmp=1":dsp_x
vars="str1=""b"":str2=""B"":cmp=1":dsp_x
vars="str1=""A"":str2=""a"":cmp=1":dsp_x
vars="str1=""B"":str2=""a"":cmp=1":dsp_x
vars="str1=""A"":str2=""b"":cmp=1":dsp_x
vars="str1=""B"":str2=""b"":cmp=1":dsp_x
</script>
HTML Web Page In-line Output:
Results on Microsoft Windows 8.1 Pro x64, Microsoft-IIS/8.5, VBScript Version 5.8 of page /internet/users/sideblog/default.asp
varsstr1, TypeNamestr2, TypeNameeval("cmda1"), TypeNameEval(cmda1), TypeNamestr1=Null:str2=Null[], Null[], Null[StrComp(str1,str2)], String[], Nullstr1=Null:str2=Empty[], Null[], Empty[StrComp(str1,str2)], String[], Nullstr1=Null:str2=""[], Null[], String[StrComp(str1,str2)], String[], Nullstr1=Empty:str2=Null[], Empty[], Null[StrComp(str1,str2)], String[], Nullstr1=Empty:str2=Empty[], Empty[], Empty[StrComp(str1,str2)], String[0], Integerstr1=Empty:str2=""[], Empty[], String[StrComp(str1,str2)], String[0], Integerstr1="":str2=Null[], String[], Null[StrComp(str1,str2)], String[], Nullstr1="":str2=Empty[], String[], Empty[StrComp(str1,str2)], String[0], Integerstr1="":str2=""[], String[], String[StrComp(str1,str2)], String[0], Integerstr1="":str2="a"[], String[a], String[StrComp(str1,str2)], String[-1], Integerstr1=Empty:str2="a"[], Empty[a], String[StrComp(str1,str2)], String[-1], Integerstr1="a":str2=""[a], String[], String[StrComp(str1,str2)], String[1], Integerstr1="a":str2=Empty[a], String[], Empty[StrComp(str1,str2)], String[1], Integerstr1="a":str2="a"[a], String[a], String[StrComp(str1,str2)], String[0], Integerstr1="a":str2="b"[a], String[b], String[StrComp(str1,str2)], String[-1], Integerstr1="b":str2="a"[b], String[a], String[StrComp(str1,str2)], String[1], Integerstr1="b":str2="b"[b], String[b], String[StrComp(str1,str2)], String[0], Integerstr1="A":str2="A"[A], String[A], String[StrComp(str1,str2)], String[0], Integerstr1="A":str2="B"[A], String[B], String[StrComp(str1,str2)], String[-1], Integerstr1="B":str2="A"[B], String[A], String[StrComp(str1,str2)], String[1], Integerstr1="B":str2="B"[B], String[B], String[StrComp(str1,str2)], String[0], Integerstr1="a":str2="A"[a], String[A], String[StrComp(str1,str2)], String[1], Integerstr1="a":str2="B"[a], String[B], String[StrComp(str1,str2)], String[1], Integerstr1="b":str2="A"[b], String[A], String[StrComp(str1,str2)], String[1], Integerstr1="b":str2="B"[b], String[B], String[StrComp(str1,str2)], String[1], Integerstr1="A":str2="a"[A], String[a], String[StrComp(str1,str2)], String[-1], Integerstr1="B":str2="a"[B], String[a], String[StrComp(str1,str2)], String[-1], Integerstr1="A":str2="b"[A], String[b], String[StrComp(str1,str2)], String[-1], Integerstr1="B":str2="b"[B], String[b], String[StrComp(str1,str2)], String[-1], Integerstr1="a":str2="a":cmp=1[a], String[a], String[StrComp(str1,str2,cmp)], String[0], Integerstr1="a":str2="b":cmp=1[a], String[b], String[StrComp(str1,str2,cmp)], String[-1], Integerstr1="b":str2="a":cmp=1[b], String[a], String[StrComp(str1,str2,cmp)], String[1], Integerstr1="b":str2="b":cmp=1[b], String[b], String[StrComp(str1,str2,cmp)], String[0], Integerstr1="A":str2="A":cmp=1[A], String[A], String[StrComp(str1,str2,cmp)], String[0], Integerstr1="A":str2="B":cmp=1[A], String[B], String[StrComp(str1,str2,cmp)], String[-1], Integerstr1="B":str2="A":cmp=1[B], String[A], String[StrComp(str1,str2,cmp)], String[1], Integerstr1="B":str2="B":cmp=1[B], String[B], String[StrComp(str1,str2,cmp)], String[0], Integerstr1="a":str2="A":cmp=1[a], String[A], String[StrComp(str1,str2,cmp)], String[0], Integerstr1="a":str2="B":cmp=1[a], String[B], String[StrComp(str1,str2,cmp)], String[-1], Integerstr1="b":str2="A":cmp=1[b], String[A], String[StrComp(str1,str2,cmp)], String[1], Integerstr1="b":str2="B":cmp=1[b], String[B], String[StrComp(str1,str2,cmp)], String[0], Integerstr1="A":str2="a":cmp=1[A], String[a], String[StrComp(str1,str2,cmp)], String[0], Integerstr1="B":str2="a":cmp=1[B], String[a], String[StrComp(str1,str2,cmp)], String[1], Integerstr1="A":str2="b":cmp=1[A], String[b], String[StrComp(str1,str2,cmp)], String[-1], Integerstr1="B":str2="b":cmp=1[B], String[b], String[StrComp(str1,str2,cmp)], String[0], Integer

Sources

  •  

Sideway BICK Blog

19/03


Copyright © 2000-2020 Sideway . All rights reserved Disclaimerslast modified on 26 January 2013