View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Henry
 
Posts: n/a
Default Setting the number of decimal places for a text box.


Try adding this to your formula:

=ROUND((your formula),2)

It will round your result to 2 decimal places.



"Aaron1978" wrote:


Hi All,

I have a user form and on that form is a text box. Data from a cell on
the worksheet is read into that text box and the user can observe it.

A simple calculation is done on the cell before it is read into the
text box. This produces a number with a large number of decimal places.
Even though I set the number of decimal places of that cell to 2 (via
right clicking on the cell and selecting "Format Cells...") the number
read into the text box still displays all the decimal places.

Could anyone tell me how I can set the number of decimal places of the
text box itself?

Best Regards,

Aaron


--
Aaron1978
------------------------------------------------------------------------
Aaron1978's Profile: http://www.excelforum.com/member.php...o&userid=31201
View this thread: http://www.excelforum.com/showthread...hreadid=519786