Decimal places in Calculated Field

  • Thread starter Thread starter Bill
  • Start date Start date
B

Bill

Hi All,

Can anyone tell me how to control the number of decimal places that are
displayed in a calculated field please.

Ta.
Bill
 
Just to add that I have used Round and FormatNumber and though I can get the
right result I need to export it all to Excel and in that it is going in as
text, even when I use format number as the last statement!!!

Help please!!
Bill
 
FormatNumber returns a string, so of course it exports as text!

If you want to export a number to Excel, then export it as a number without
formatting. Access cannot control how Excel displays the number, you will
need to set the appropriate formatting within Excel.
 
Just to add that I have used Round and FormatNumber and though I can get the
right result I need to export it all to Excel and in that it is going in as
text, even when I use format number as the last statement!!!

Note that Excel has only one native numeric data type, being double
floating point in nature; Excel has no fixed decimal numeric type to
map to. Therefore, you can either apply the formatting on the 'Access
side' converting the result to text or retain the value as numeric and
apply formatting on the 'Excel side'.

Jamie.

--
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top