Formatting values in textbox

  • Thread starter Thread starter Hallgeir
  • Start date Start date
H

Hallgeir

Can anyone help me with this?

I have a value field in my report. I want the value to be formatted with two
decimals and I want the field to show nothing or just '-' if the value in
the field is 0.
Eks: Value 1235,1 formatted : 1 235,10
Value 0,00 formatted: -
Value -10,3 formatted -10,30

I'have tried with different combinations of the # char. used on the format
property. But I just don't seem to get it right.

I appreciate any hint and answers.
 
Can anyone help me with this?

I have a value field in my report. I want the value to be formatted with two
decimals and I want the field to show nothing or just '-' if the value in
the field is 0.
Eks: Value 1235,1 formatted : 1 235,10
Value 0,00 formatted: -
Value -10,3 formatted -10,30

I'have tried with different combinations of the # char. used on the format
property. But I just don't seem to get it right.

I appreciate any hint and answers.

To show the - if the value is 0:
Set the format property of the control to

#,00;-#,00;-

or...
to show nothing if the value is 0:
Set the format property of the control to
#,00;=#,00;""

In Access help see
Format Property + Number and Currency Datatype
 
To show the - if the value is 0:
Set the format property of the control to

#,00;-#,00;-

or...
to show nothing if the value is 0:
Set the format property of the control to
#,00;=#,00;""

In Access help see
Format Property + Number and Currency Datatype

Thanks Fred! Just what I was looking for.

regards Hallgeir
 
Back
Top