Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sorry to be such a Dullard!
Message
 
 
À
25/07/2010 21:22:10
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
01473802
Message ID:
01473827
Vues:
57
This message has been marked as a message which has helped to the initial question of the thread.
>>>That was painless....(FOR ME!) thanks for the help!
>>>
>>>dg
>>
>>Great! The following general principles may also help you in other programming tasks:
>>
>>1. Variables declared in one method will not be available in another method of the same form. Form-level properties solve this problem. (Public variables are an abomination unto the Lord. - Well, they may be used on rare occasions, but this is not one of them.)
>>
>>2. These properties may also be objects.
>>
>>Note that sometimes you will get a dangling object reference. If you have trouble closing a form, it may be that somewhere else you still have a reference to your form.
>
>What variable, value or condition do I check to check the existence of "ThisForm.OtherForm"? I want to make sure the new form is closed before it is called again, because the form creates a cursor to populate the data, and the initial cursor would be destroyed thus causing a problem when returning to the first open instance. Is there a conditional statement to test before issuing ThisForm.OtherForm.Release() ?
>
>This could also be applied when closing the first form as well (if I follow your discussion with Naomi).
>
>Thanks,
>
>dg

To check for existence:

if type('thisform.OtherForm.Name') = 'C'
* Form is alive
endif
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform