Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Which comes first
Message
De
26/01/2004 12:20:56
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
26/01/2004 12:12:31
Joel Hokanson
Services Integration Group
Bellaire, Texas, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00870624
Message ID:
00870628
Vues:
15
>Which comes first on a form Init or Load?
>
>I want to open a table, store a value to a memvar and use trhat memvar as teh control source for a text box.
>
>When should I do that?

Load() comes before Init(). Specifically, Form.Load() is executed before the Init() of contained objects, Form.Init() is executed after the Init() of contained objects.

This makes Load() the ideal place to prepare tables, since otherwise, contained controls may report an error (could not bind controlsource, or something similar).

Also, since Form.Init() executes after the Init() of the contained objects, you can control the contained objects from there, for instance, change the .Visible or the .ReadOnly property, depending on some condition.

Greetings,

Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform