Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
What was the last object I had focus on?
Message
De
05/08/2010 02:45:44
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
À
04/08/2010 18:23:31
James Blackburn
Qualty Design Systems, Inc.
Kuna, Idaho, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Novell 6.x
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01475139
Message ID:
01475248
Vues:
61
>The only way I know to do this is to add code in your base class lostfocus() event that saves itself to a form property.
>
>IF PEMSTATUS(thisform,"olastactivecontrol",5)
>	thisform.olastactivecontrol = this
>ENDIF 
>
Actually without the test
thisform.addproperty("olastactivecontrol", this)
And don't forget to
thisform.olastactivecontrol=null in form's .destroy(), to avoid having a dangling reference. In one case when I was doing something similar, for some reason storing direct references didn't work, so I used sys(1272, this) instead, with a catch that the first segment of its result is a temporary variable before form's init exits, and isn't too usable afterwards either - to use it, I had to replace it with "thisform.", which worked inside the form.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform