Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Release program from memory
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
01062188
Message ID:
01062780
Views:
15
>>>Hi,
>>>
>>>If I instantiate a class from another executable like:
>>>
>>>objPrograma = NewObject("Programa", "Programa.VCX", "Auxiliar\Programa.EXE")
>>>
>>>
>>>If I try to rename Auxiliar\Programa.EXE isn't possible because the class Programa is in the memory.
>>>
>>>How can I release Auxiliar\Programa.EXE from memory to rename it ?
>>>
>>>I can do like this:
>>>
>>>objPrograma = NewObject("Programa", "Programa.VCX", "Auxiliar\Programa.EXE")
>>>objPrograma.SomeMethod()
>>>Release objPrograma
>>>Rename Auxiliar\Programa.EXE to Auxiliar\Programa_OLD.EXE
>>>
>>
>>In addition to what Sergey told you, you might also want to release the variable holding the object reference.
>
>
>Holding the object reference?...
>like:
>
>Release objPrograma
>
>
>Don't works... it realeases the objPrograma object from memory, but if I try to rename the file like:
>
>Rename Auxiliar\Programa.EXE to Auxiliar\Programa_OLD.EXE
>
>I don't possible because the Programa.EXE are in the memory

No, I mean
objPrograma.Destroy
objPrograma = NULL
RELEASE objPrograma
I know you have the release, but you never destroy the object. Check to make sure that Destroy actually works.
George

Ubi caritas et amor, deus ibi est
Previous
Reply
Map
View

Click here to load this message in the networking platform