DBGrid and DBEdit with Masks 
Author Message
 DBGrid and DBEdit with Masks

I'm new in delphi programming.
Can someone please show me an example how to define an EditMask for a
DBEdit or DBGrid field to show decimal separator ',' and always to
numbers (even if 0) after the separator.
Many thanks.

Dieter Krebs



Wed, 18 Jun 1902 08:00:00 GMT  
 DBGrid and DBEdit with Masks
On Mon, 18 Jan 1999 12:31:57 -0800, Dieter Krebs

Quote:

>I'm new in DELPHI programming.
>Can someone please show me an example how to define an EditMask for a
>DBEdit or DBGrid field to show decimal separator ',' and always to
>numbers (even if 0) after the separator.

You should use the underlying TNumericField.DisplayFormat property and
set it to something like: #.00

Regards,

--
Marco Rocci
MicroEra srl
Turin, Italy



Wed, 18 Jun 1902 08:00:00 GMT  
 DBGrid and DBEdit with Masks

Quote:

>I'm new in DELPHI programming.
>Can someone please show me an example how to define an EditMask for a
>DBEdit or DBGrid field to show decimal separator ',' and always to
>numbers (even if 0) after the separator.
>Many thanks.

Hi Dieter,

You need to define the Tfields in your dataset.  Double click on your dataset.
A fieldsEditor box will come up.  Right click on it and choose Add Fields.
Another box will come up with the list of fields that your dataset has.  Click
Ok on that box to add the fields to your other editor.  Once you have done
that, click on the field that you want to alter and push the F11 key to go to
the object inspector.  Put 00.00 in the DisplayFormat property.

HTH.

********************************
Michael Glatz




Wed, 18 Jun 1902 08:00:00 GMT  
 DBGrid and DBEdit with Masks
Hello,

Doubleclick your table icon and select add fields.
Thereafter, when you click a fieldname you get a Display format property
which you can input 00.00

Remember though, that making your fields persistent like this will require
that you repeat add fields if you create new fields in your table. If not
you will get some yelding error messages.

--
Regards
Kai Inge

{When I realized the difference between estimated time used and real time
used - I realized that the life is going to be too short.}

Quote:

>I'm new in DELPHI programming.
>Can someone please show me an example how to define an EditMask for a
>DBEdit or DBGrid field to show decimal separator ',' and always to
>numbers (even if 0) after the separator.
>Many thanks.

>Dieter Krebs



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. DBEdit Components and Edit Masks

2. Masks, DBEdit, dates and NULL values

3. DBEdit (Masking input - Float fields)

4. Edit masks for DBEdit

5. Input Mask for DBEdit?

6. Masked DBEdit : D3

7. PARADOX Mask-Defs not DBEdits ?? Why Whow

8. masks on dbedit fields...

9. D4: Masking filelds in DBGrid

10. Delphi Edit Mask in DBGrid help please!!!!

11. masking TQuery fields or DBGrid columns

12. DBEdit ... masked?

 

 
Powered by phpBB® Forum Software