Subject | Re: DisplayFormat Problem |
---|---|
Author | stanw1950 |
Post date | 2002-07-18T21:27:47Z |
Now I notice that the formating doesn't work on the first entry into
the tib_edit in edit mode. Do I need to set the editmask property
and, if so, what can I set it to to get a float field to only display
2 decimal positions when the edit box is tabbed into? Once the user
starts typing, more than 2 decimal positions can be displayed, but
when the user tabs to the next edit box, only 2 should display.
Thanks again.
the tib_edit in edit mode. Do I need to set the editmask property
and, if so, what can I set it to to get a float field to only display
2 decimal positions when the edit box is tabbed into? Once the user
starts typing, more than 2 decimal positions can be displayed, but
when the user tabs to the next edit box, only 2 should display.
Thanks again.
--- In IBObjects@y..., "stanw1950" <stanw@e...> wrote:
> I have a tib_edit control linked to a float data field from a
> tib_query. I have set the DisplayFormat property to 0.00;;#. The
user
> is allowed to enter as many decimal positions as he wants, but only
> two position will show. When the query is placed in edit mode and
the
> field is tabbed to everything is fine. If the value is 11.11, that
is
> what is displayed. If the user changes it to 11.1112 and tabs out
of
> the field, then 11.11 is displayed. But when the user tabs through
> all the controls (still in edit mode) and returns to the 11.11
field,
> 11.109999656 displays (the actual float value). Why did the
> formating work the first time through but not after that? I messed
> around with the EditMask format, but that made things worse.
>
> Thanks in advance. (ibo 4.2.hg; delphi 6 ent)
>
> Stan Walker