FIX: RELEASE Releases All Local Variables with Identical NamesID: Q142214 3.00 3.00b WINDOWS kbprg kbbuglist kbfixlist The information in this article applies to:
SYMPTOMSWhen the RELEASE <memvar> command is called to release a LOCAL variable, all variables that have that same name are also released. For example, a local variable that is declared in a higher level procedure and is not visible in the current routine is released when the RELEASE <memvar> command is issued.
WORKAROUNDBecause local variables are out of scope as soon as you call another program, you can avoid using the RELEASE command to explicitly release a local variable. You can also use the RELEASE ALL command instead of RELEASE <memvar>. For example, instead of using this:
use this:
The RELEASE ALL command does not release local variables that have been
declared in other procedures or functions, even if they have the same name
as a local variable in the current procedure.
STATUSMicrosoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem has been fixed in Visual FoxPro 5.0 for Windows.
MORE INFORMATION
Steps to Reproduce ProblemTo reproduce the problem, copy the following sample code into a program file, and run it:
KBCategory: kbprg kbbuglist kbfixlist
KBSubcategory: FxprgGeneral VFoxWin buglist3.00 buglist3.00b fixlist5.00
Additional reference words: 3.00 3.00b
|
Last Reviewed: February 23, 1997 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |