How to copy custom number formats

S

Simon Lenn

Hello All

I have a custom number format for a Excel Cell A1 which is #,##0.00
"CAD"

and in A1 I now have a value 1000 CAD.

I have assigned cell B1 as =A1 but an external application when the
report is run populated now cell A1 as 20000 MXP and now my cell B1
says 20000 CAD and not 20000 MXP and when I check the format for B1 it
still as the format as
#,##0.00 "CAD" whereas now the format of my cell A1 is #,##0.00
"MXP" appears only the value and not the format is being copied.

Can any of you suggest a workaround to resolve this problem.

Many thanks
Simon Lenn
 
D

Debra Dalgleish

A formula can return a value, but not a format. You can copy the format
from A1 manually, or programmatically, to cell B1.
 
D

Dave Peterson

So this external program changes the numberformat for A1
from #,##0.00"CAD"
to #,##0.00"MXP"

The bad news is functions won't copy the numberformat from one cell to another.
You either have to do it manually or have a macro do it. (Maybe you could have
the same external program that updates the numberformat of A1 do B1, too???)
 

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

Top