John,
VFP isn't going to release memory back to the OS as objects are destroyed. sys(1016) isn't a reliable measure of memory use immediately after object release, it takes time before the value actually drops back down. Run this code line by line from the command window to see:
activate window "debug output"
clear all
debugout sys(1016)
ox = crea("form")
debugout sys(1016)
ox.Visible = .t.
debugout sys(1016)
ox = .null.
debugout sys(1016)
debugout sys(1016) && wait a while between executing these
debugout sys(1016) && you'll see a gradual decrease
debugout sys(1016) && in the value, it will eventually become stable
clear all
debugout sys(1016) && not quite what it was at the start of the exercise...
>I have a simple test on memory usage using SYS(1016) for my application. I found that, the value returned by SYS(1016) is increased even my forms, business objects are released properly (there are no any datasession hanging). How could I indentify what cause?
>
>Also, I have a small test by just create simple object such as session and form class. After I release the object, the memeory usage returned by SYS(1016) is still higher. Why?