diff options
Diffstat (limited to 'wizards/source/tools/Strings.xba')
-rw-r--r-- | wizards/source/tools/Strings.xba | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/wizards/source/tools/Strings.xba b/wizards/source/tools/Strings.xba index 7a5e8872cac8..6dce4d6695f5 100644 --- a/wizards/source/tools/Strings.xba +++ b/wizards/source/tools/Strings.xba @@ -261,6 +261,24 @@ Dim CurFieldValue End Function +' Searches for a Value in multidimensial Array by querying all Searchindices of the passed dimension +' and delivers the Index where the Searchvalue is found as a part string +Function GetIndexForPartStringinMultiArray(SearchList(), SearchValue, SearchIndex as Integer) as Integer +Dim i as integer +Dim MaxIndex as Integer +Dim CurFieldValue + MaxIndex = Ubound(SearchList(),1) + For i = Lbound(SearchList()) to MaxIndex + CurFieldValue = SearchList(i,SearchIndex) + If Instr(CurFieldValue, SearchValue) > 0 Then + GetIndexForPartStringinMultiArray() = i + Exit Function + End if + Next + GetIndexForPartStringinMultiArray = -1 +End Function + + Function ArrayfromMultiArray(MultiArray as String, iDim as Integer) Dim MaxIndex as Integer Dim i as Integer |