>If the function is an excel function, why not simply put the expression in the .formula property of the cell? If, OTOH, it's a VFP function, why not just store the result?
>
>The elegance of the answer would depend a lot on the circumstances - like, is this a sheet you are generating from Fox periodically, or is it a permanent sheet that you update from Fox, and in the latter case, whether the numbers in it all come from Fox or from other sources too (like manual entry or being created/updated by other software).
Hello , Dragan
My main desire is to achieve flexibility. Accountants are prone to changing their reports. If i store the results from the app directly into cells then every time a report (xls) changes i will have to rewrite the VFP code. If , on the other hand, i store in a comment a VFP expression that the app just evaluates, then what i have to do is to supply a new xls which tells the app what to do and i don't have to rewrite the code.
Regards
Kamil
A moment of silence is our cosmic reset button.