Compares a clsD3DynamicArray with the specified string and if equal, returns True.
bValue = object.brEqualStr( sItem)
Parameter | Description |
---|---|
bValue | The return value is a Boolean data type that is True if equal. |
object | An object variable that represents a clsD3DynamicArray object. |
sItem | The String to be compared. |
To make the comparison, the brEqualStr method converts the clsD3DynamicArray object to a string. If both strings contain numeric information, then a numeric comparison is made, otherwise, a string comparison is made.
Sub Main() Dim oEnv As New clsD3Environment Dim oDynArray1 As clsD3DynamicArray Dim oDynArray2 As clsD3DynamicArray Dim sStr As String Set oDynArray1 = oEnv.brOpenDynamicArray Set oDynArray2 = oEnv.brOpenDynamicArray oDynArray1.brInsertStr "Allen", 1 oDynArray1.brInsertStr "Kevin", 2 sStr = "Allen" & D3AMChr & "Kevin" If oDynArray1.brEqualStr(sStr) Then Debug.Print "The dynamic arrays are equal" End If oDynArray2.brCString = sStr If oDynArray1.brEqual(oDynArray2) Then Debug.Print "The dynamic arrays are equal" End If End Sub