Hi Bill,
They didn't fix that bug for array properties. Here's a repro.
oTest = NEWOBJECT("test")
DIMENSION oTest.laList[10]
FOR i=1 TO ALEN(oTest.laList)
oTest.laList[i] = REPLICATE(TRANSFORM(i), 250+i)
ENDFOR
FOR EACH lcStr IN oTest.laList
? LEFT(lcStr,20), LEN(lcStr)
ENDFOR
RETURN
DEFINE CLASS test AS custom
Name = "test"
DIMENSION laList[10]
ENDDEFINE
You can either change your code to use FOR ... ENDFOR loop or use array variable instead of property array in FOR EACH loop.
>Hi Sergey,
>This is the code that busted.
>I think this is all the pertinent code.
>If you want I can show you everything.
>I was wrong in my first message. The next line is 273 characters long.
>Note this test.
>
>I tried the example from mskb #
Q305238>this does not crash when I execute it from the command window.
>
>DIMENSION laX(1)
>laX(1) = SPACE( 273 )
>FOR EACH lcX IN laX
> ? lcX
>NEXT
>
<snip>>
>
>>Hi Bill,
>>
>>It suppouse to be fixed in VFP7. See
FIX: FOR...EACH Fails When Character Array Element Contains More Than 255 Characters mskb #
Q305238. Can you post HTML that causes this problem, if it's not to big?
>>
--sb--