
Edward A. answered 05/22/19
Clear tutor: Excel formulas, graphs, pivot tables, macros, What-Ifs
((Late answer from 12 July. When I followed my own advice, I got a different code.
Selection.NumberFormat = “_($* #,##0.00_);_($* (#,##0.00);_($* “”-“”??_);_(@_)”
Try that and see how it works.))
One way to find out is to have Excel show the code it would use to make the manual reformatting.
To be concrete, perform the following:
1) Start Macro
2) select a cell that is not yet in accounting form
3) hit alt-h-fm to change the cell to accounting form
4) End Macro
Now read the code that Excel generated for your action.