Hi!
Probably, the difference is because APPLICATION is a reference to OLE application, and thus object references returned by using it are different - they passed through the bounds of COM.
>Hi All,
>I run VFP7 SP1
>I found a problem with APPLICATION.ACTIVEFORM. Every of my forms Owns a Method GetSettings wich returns Settings in a Array
>
>If I run
>
>*make sure we have APPLICATION.ACTIVEFORM
>...
>loForm = APPLICATION.ACTIVEFORM
>loForm.GetSettings(@laSettings)
>...
>
>laSettings remains unchanged. If single step it, I can see the parameter changing in GetSettings but laSettings is not changed.
>
>If I catch an other reference to the form using SYS(2017) the Array is changed.
>
>If I compare loForm with the reference from sys(2017) it returns .f.
>
>But it is the same object!
>
>So I play arround and found finaly:
>*make sure we have _SCREEN.ACTIVEFORM
>...
>loForm = _SCREEN.ACTIVEFORM
>loForm.GetSettings(@laSettings)
>...
>
>
>it runs.
>
>If I compare loForm with the reference from sys(2017) now it returns .t. (as expected)
>
>So, where is the differnce between APPLICATION.ACTIVEFORM and _SCREEN.ACTIVEFORM?
>
>Any suggestion is welcome
>
>Agnes
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.comICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs
It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.