Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Vfp 8.0 newbie question
Message
De
09/10/2003 08:00:53
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00836708
Message ID:
00836720
Vues:
13
There is nothing at all wrong with Nick's response, but I think a better approach would be to create your own textbox class based on the Fox base textbox class. It's something you should do with all of the Fox controls and classes anyway.

In your own textbox class, add a property called OriginalTop (same for the other position and size properties if you like).

In your new textbox's init, just add:
This.OriginalTop = This.Top
From then on, use your own controls rather than Fox's base controls. Later, when you subclass your textbox control to create whatever (datebox control, for example?), you won't have to rewrite the code each time - the behaviour will simply be inherited by your subclasses.

Alan

>i'm having a little problem with what i assume is a simple question. say i have a form designed with a text box where the ".top" property of that textbox is 100. when the program is running i move the textbox up and down the screen by programmatically changing the value of ".top". while the program is running how do i determine the original design-time value of ".top". i am basically adding a "reset to default button" and want the text box to return to its original position of ".top=100". i am assuming that value is accessible and i don't have to create a variable to store it.
>
>thanks,
>
>nancy
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform