Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Copy format codes from Format -> Cells, Number, Currency into a lookup table.

D             E
~~~~~~~~  ~~~~~~
currency  format
USD       [$$-409]#,##0.00;[RED]-[$$-409]#,##0.00
EUR       #,##0.00 [$€-612];[RED]-#,##0.00 [$€-612]

Now use the TEXT function and look up the format. Enter the following formula for A2.

=TEXT(250000;VLOOKUP(B2;D$2:E$3;2))

The result:

formatted currency values

Copy format codes from Format -> Cells, Number, Currency into a lookup table.

D          E
~~~~~~~~  ~~~~~~
currency  format
USD       [$$-409]#,##0.00;[RED]-[$$-409]#,##0.00
EUR       #,##0.00 [$€-612];[RED]-#,##0.00 [$€-612]

Now use the TEXT function and look up the format. Enter the following formula for A2.

=TEXT(250000;VLOOKUP(B2;D$2:E$3;2))

The result:

formatted currency values