>Build an exe file with debug info checked in Project Manager.
>Run it in stand-alone mode and look for message(1) value
>set by error.
>
>What does the line returned by message(1) mean ? It seems that
>it returns some random line from program !?
>I cannot see any reason why it is a line from totally different
>part of program!
Just for your confirmation, I get this too.
FWIW, I have observed that the lines of code that make it into the error log produced by MESSAGE(1) are usually of a certain type of code consisting of table functions and SQL. Interesting, but I have found no other patterns.
The really intersting part, is that sometimes the line of code that it returns, is ont even your line of code, but an SQL statement that VFP built internally from a view operation (USE, SELECT, UPDATE DELETE, etc). I have gained a lot of insight from seeing these 'internals' exposed on accident by MESSAGE(1).
Erik Moore
Clientelligence