>>>The end of this is a simple
>>>
scatter name oSomething memo
>>>with oSomething
>>> nErrorCount=myBigValidationFn()
>>>endwith
>>>which then works nicely even in a scan/end loop, and I don't even care who called it, from where, and what was the alias. And it's very fast.
>>
>>Hi Dragan
>>
>>I'd have created a memvar and passed it to the rules as a parameter. If each had the parameter from the start you would not have any gain from the with construct. What will you do if you needed nested WITH? It's a best practice to send parameters to a function to encapsulate it. This approach is not one that shows any advantage to WITH. :)
>
>And the cost of passing a parameter and parsing its properties 30000 times vs properties being accessed in the WITH context? Consider that this has to happen in real time, i.e. between a click and the time the user expects to see some results.
Passed by reference, is it any worse than the WITH? Certainly more obvious what object is being acted upon? :)