title: Excel formula to return a cell's custom format
body: <p>I'm trying to normalize data by reading a custom number format.  The actual data in the following cells only have the values 3 and 33</p>
  
  <pre><code>[A1]  3 CASES
  [A2]  33 UNITS
  </code></pre>
  
  <p>The terms "CASES" and "UNITS" are displayed because they are part of the custom format distinct to each cell.  e.g. 
  A1 has custom number format code:  # "CASES", and A2 has custom number format code: # "UNITS"</p>
  
  <p>I would like to normalize this data via an excel formula into UNITS for reporting purposes.  I attempted to use the formula </p>
  
  <pre><code>=CELL("format",A1)
  </code></pre>
  
  <p>but the value returned is F0 instead of: # "CASES"</p>
  
  <p>If each CASE has 5 units I am expecting to have an additional column that computes NORMALIZED UNITS with a formula that reads something like:</p>
  
  <pre><code>=IF(CELL("format",A1)="CASES",5*A1,A1)
  </code></pre>
  
  <p>This way the NORMALIZED UNITS in column B would be</p>
  
  <pre><code>[B1]  15
  [B2]  33
  </code></pre>