Information générale
Catégorie:
Codage, syntaxe et commandes
>Hi,
>Is it possible to store a property value/call a method of all instance objects in form without have to loop thru all controls?
>
>Thank you
Container.SetAll('PropertyName','Value','Class')
There is no way to call a method that I know of. Of course, you could do the above and if your property has an assign method that will fire. Kevin McNeish wrote an article on using this method to have 'poor mans' events in VFP.
Of course, if VFP 8.0 the event binding is essentially what are you asking for. You bind, for example, the 'DoItAll' method of your form to the 'FormDoAll' method of your controls. When you call the DoItAll() or raise it as an event, then all the FormDoAll methods bound to it will fire.
BOb
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement