Hi Agnes,
I'm not sure how fast it's but it's short and easy to test. :)
DIMENSION laStrings[2]
laStrings[1] = "ABCDEFGHIJ"
laStrings[2] = "0123456789"
lnStrCount = ALEN(laStrings)
lnStrLen = LEN(laStrings[1])
lcStr = ""
FOR i=1 TO lnStrLen
FOR j=1 TO lnStrCount
lcStr = lcStr + SUBSTR(laStrings[j], i, 1)
ENDFOR
ENDFOR
? lcStr
>
>I'm looking for the fastest way to interleave strings.
>Problem:
>
>*given strings
>lc1 = 'ABCDEFGHIJ'
>lc2 = '0123456789'
>
>*Result
>='A0B1C2D3E4F5G6H7I8J9'
>
>
>I need to interleave 2,4,6, 8 or 10 strings (a 1 string interleave exists too)
>The string lenght is even.
>
>(For those interested, this is the error corection on a DataMatrix Barcode, see
http://grandzebu.net/index.php?page=/informatique/codbar/datamatrix.htm and
http://grandzebu.net/informatique/codbar/datamatrix.xls)
>
>I appreciate any idea
>
>Agnes
--sb--