 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Martin Frey Guest
|
Posted: Wed Sep 08, 2004 1:23 pm Post subject: Renderer/Editor of a column with float value |
|
|
Hi
if i have a column that shows float values i get a display problem. Even if
i set the precision and/or scale of the column, the formatter doesn't care
about it.
So if the value is 0.001 it's shown correctly, but if the value if 0.0001
it's shown as 0. If i start editing the cell the value appears correct as
1.0E-4. So i think it's only a problem of the renderer. Does someone know
how i can get the renderer work correct? I can use the setFormatter() and
setPattern("######.########") but how can i change the pattern if i wana
display 0.001 and then 1.0E-4?
I use JBuilderX.
Thank you
Martin
|
|
| Back to top |
|
 |
Paul Nichols (TeamB) Guest
|
Posted: Fri Sep 17, 2004 5:25 am Post subject: Re: Renderer/Editor of a column with float value |
|
|
Martin Frey wrote:
| Quote: | Hi
if i have a column that shows float values i get a display problem. Even
if i set the precision and/or scale of the column, the formatter doesn't
care about it.
So if the value is 0.001 it's shown correctly, but if the value if 0.0001
it's shown as 0. If i start editing the cell the value appears correct as
1.0E-4. So i think it's only a problem of the renderer. Does someone know
how i can get the renderer work correct? I can use the setFormatter() and
setPattern("######.########") but how can i change the pattern if i wana
display 0.001 and then 1.0E-4?
I use JBuilderX.
Thank you
Martin
I am assuming that this is in a JdbTable, right? What is the settings for |
the Table Column (ie Field) in the QueryDataSet, as far as precision?
|
|
| Back to top |
|
 |
Martin Frey Guest
|
Posted: Mon Sep 20, 2004 8:40 am Post subject: Re: Renderer/Editor of a column with float value |
|
|
Yes it is in a jdbTable, but i think i doesnt matter. I solved it just yet
it's an oracle database and i had to set the datatype, sqlType to Double and
instanciate a new DoubleFormatter: column.setFormatter(new
DoubleFormatter(com.borland.dx.dataset.Variant.DOUBLE));
Jdbc and dataexpress is a "little" bit confusing sometimes. haha
Oh yes and in a jbuilder update it would be great if the SqlType of a column
would be java.sql.Types.DOUBLE and just a value ;)
Regards Martin.
"Paul Nichols (TeamB)" <paul (AT) comp (DOT) net> wrote
| Quote: | Martin Frey wrote:
Hi
if i have a column that shows float values i get a display problem. Even
if i set the precision and/or scale of the column, the formatter doesn't
care about it.
So if the value is 0.001 it's shown correctly, but if the value if 0.0001
it's shown as 0. If i start editing the cell the value appears correct as
1.0E-4. So i think it's only a problem of the renderer. Does someone know
how i can get the renderer work correct? I can use the setFormatter() and
setPattern("######.########") but how can i change the pattern if i wana
display 0.001 and then 1.0E-4?
I use JBuilderX.
Thank you
Martin
I am assuming that this is in a JdbTable, right? What is the settings for
the Table Column (ie Field) in the QueryDataSet, as far as precision?
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|