David,
>
>I just singled out substr(), any string function can fail in this way under VFP5.
>
>I'll bet the error is here:
>
>
lcSourceTbl=lcState+"SAL"+right(lcYear,2)
>
>What is the value of lcYear when the code tries to run?
How much money did you bet? :)
lcYear='2000' before it runs ... Let's call it a miracle, if you don't like 'bug'...
This is totally weird and I'm tired to try again and again :( VFP6.0 is definitely better, although it's not ideal too.
>
>>I'm sure, I didn't do such a thing!!!! :)
>>This is my lcWhere expression: (from debugger)
>>ccode='13' and aa.ccode+aa.town=bb.County+bb.town
>>
>>No substr at all...
If it's not broken, fix it until it is.
My Blog