Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Formating display of floating point numbers
Message
De
09/08/2011 11:08:16
 
 
À
09/08/2011 06:57:07
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
Database:
MS SQL Server
Divers
Thread ID:
01520460
Message ID:
01520503
Vues:
51
>>>I have *lots* of fields that are B(16)
>>>
>>>If I want to display that number rounded to the fourth decimal, for example, in a textbox what are my options for formatting the display ( assuming not just creating a dummy display field and converting the number )
>>>
>>>Seems there should be an easy trick to it, but I'm not seeing a format that looks right and I can't use an input mask for display - or can I ?
>>
>>Why not ?
>>Perhaps transform() function might be helpful as well.
>>
>>Hey, You better be careful ! Where you are at, one nasty bug might cost world economy trillions of dollars.
>>Uuuups... There goes another 500pts plunge ... {g}
>
>Yes, friends and family have noticed that since I have been consulting at Dow Jones the index has not been ... climbing <g>
>
>But the software I am redesigning hasn't gone into production yet, so if I am lucky the release will coincide with the up that will eventually come after the down.
>
>Or maybe I'll just build something in to make it *look* like an up, anyway <bg>

with a stand alone textbox you can put the code into the textbox refresh method:
textbox::Refresh && load the value
this.InputMask = ICASE(m.this.value=CONDITION1,MASK1,CONDITION2,MASK2....)
NODEF
on grid the dynamicInputMask is not stable
then you can work with dynamicCurrentControl
o another other dynamic expression.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform