Custom Number Format Question - Spacing

Gebo

New Member
Joined
Jan 6, 2006
Messages
3
Hello,

Hoping someone can help me with a custom formatting question...

I have a need to display numbers with a dollar sign as shown below (please assume the underline symbols I'm using for spacing aren't there - I don't want the underlines, but I couldn't get the text to line up without them):

__$_9999
__$(9999)
__$__999
__$_(999)


Not sure this will look quite right on the screen, but the key points are that 1) the dollar signs must line up, 2) the dollar signs cannot be left justified, but instead need to be a set number of characters from the left side, 3) in the event of a negative, the parens should enclose just the number and not extra spaces, and 4) the right-hand digits should line up.

I have accomplished most of these, but my problem is with the opening paren on negative numbers. The format I've made is:

$_(????_);$(????)

The problem I have is that I'm getting:


__$_9999
__$(9999)
__$__999
__$(_999)


Where for the fourth number, the paren is enclosing both the number and the spaces I drove because I used the ? symbol...

Can anyone think of a way to modify the custom format to get the paren to move with the number?

Thanks much in advance,

Gebo
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.

Forum statistics

Threads
1,215,054
Messages
6,122,895
Members
449,097
Latest member
dbomb1414

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top