>I figured this out. Change you ERROR metod
>FUNCTION Error
>PARAMETER nError,cMethod,nLine
><b>MESSAGEBOX('ErrorMethod')</b>
>RETURN TO ShowMessage
and run your code. You wouldn't see ErrorMethod message because COUNT FOR IRegion=lnRegion doesn't generate an error!
>
>To confirm it just run COUNT FOR IRegion=lnRegion from command window on any open table.
>You can use
Yes, you are right. Count doesn't fire up an error. How could that be? I need it to fire on error. Do you know why this VFP function doesn't fire an error? It's amazing to see the reaction of the Count function.