title: How to use a conditional operator in a custom number format for dates and times in Excel?
body: <p>How to use a conditional operator in a custom number format for dates and times in Excel?</p>
  
  <p>If I have a column of numbers, I can use a custom number format to display a singular or plural word.</p>
  
  <p>Right click cell > Format Cells... > Number > Category: Custom > Type:</p>
  
  <pre><code>[=1]# "item";# "items"
  </code></pre>
  
  <p>> OK</p>
  
  <p>For a cell containing 1, the custom number format displays "1 item".</p>
  
  <p>For a cell containing 7, the custom number format displays "7 items".</p>
  
  <p>Likewise, I want to do the same with time.</p>
  
  <p>If I have a column of times, such as 00:01:00, 00:20:00, 00:25:00, etc., I want to display "1 minute", "20 minutes", "25 minutes", etc.</p>
  
  <p>I first tried <code>[=1][m] "minute";[m] "minutes"</code>, but it turns out that 1 means 24 hours or 1 day.</p>
  
  <p>The value of 1 minute is</p>
  
  <pre><code>1 / 24 / 60 = 1 / 1440 = 0.0006944444444444444444444444...
  </code></pre>
  
  <p>I tried entering a fraction, but the <code>[=1/1440]</code> in <code>[=1/1440][m] "minute";[m] "minutes"</code> turns into <code>[=1]</code>.</p>
  
  <p>Unfortunately, I tried <code>[=0.000694444444444444][m] "minute";[m] "minutes"</code>, but that does not work.</p>
  
  <p>The following works, but I want to use an exact minute value.</p>
  
  <pre><code>[&lt;=0.000694444444444445][m] "minute";[m] "minutes"
  </code></pre>
  
  <p>Is there a format for 1 minute that works?</p>
  
  <hr>
  
  <p>Here is the documentation on the custom number format:</p>
  
  <ul>
  <li><p>Create or delete a custom number format:</p>
  
  <p><a href="http://office.microsoft.com/en-us/excel-help/create-or-delete-a-custom-number-format-HA102749035.aspx" rel="noreferrer">http://office.microsoft.com/en-us/excel-help/create-or-delete-a-custom-number-format-HA102749035.aspx</a></p></li>
  </ul>