ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   cell format text and data displayed like a number (https://www.excelbanter.com/excel-programming/408194-cell-format-text-data-displayed-like-number.html)

RC[_7_]

cell format text and data displayed like a number
 
I would like to have the cell format set as text but display numbers
like $123,456.1234 while still having the data be just 123456.1234
I know that it would be easier to set the cell format to number, but I
want to manipulate the data and the number format messes that up. I
can start out with the cell format set at text, manipulate the data,
and -then- set the cell format to number to get the proper display,
which works fine until the user enters a number in that cell a second
time and now the format is set to number.

JLGWhiz

cell format text and data displayed like a number
 
Use FormatCellsCustom then in the box above the suggested custom styles
type:

"$###,##0.0000_"; ($###,##0.0000)

Then click OK

"RC" wrote:

I would like to have the cell format set as text but display numbers
like $123,456.1234 while still having the data be just 123456.1234
I know that it would be easier to set the cell format to number, but I
want to manipulate the data and the number format messes that up. I
can start out with the cell format set at text, manipulate the data,
and -then- set the cell format to number to get the proper display,
which works fine until the user enters a number in that cell a second
time and now the format is set to number.


JLGWhiz

cell format text and data displayed like a number
 
Or, just select currency and set the decimal places to 4.

"RC" wrote:

I would like to have the cell format set as text but display numbers
like $123,456.1234 while still having the data be just 123456.1234
I know that it would be easier to set the cell format to number, but I
want to manipulate the data and the number format messes that up. I
can start out with the cell format set at text, manipulate the data,
and -then- set the cell format to number to get the proper display,
which works fine until the user enters a number in that cell a second
time and now the format is set to number.


RC[_7_]

cell format text and data displayed like a number
 
On Mar 23, 2:17 pm, JLGWhiz wrote:
Or, just select currency and set the decimal places to 4.

"RC" wrote:
I would like to have the cell format set as text but display numbers
like $123,456.1234 while still having the data be just 123456.1234
I know that it would be easier to set the cell format to number, but I
want to manipulate the data and the number format messes that up. I
can start out with the cell format set at text, manipulate the data,
and -then- set the cell format to number to get the proper display,
which works fine until the user enters a number in that cell a second
time and now the format is set to number.


Thanks, I will try both of the above suggestions, it looks like they
don't mess up the data, so I can still manipulate the numbers as a
'text' string.


All times are GMT +1. The time now is 02:34 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com