title: Validate string entry
body: <p>I need to validate a Social Security Number (SSN) in Excel. I don't know where to start and I've looked everywhere on the web, but to no avail ... Please help if you can. Thanks.</p>
  
  <p>Here are the validation rules:</p>
  
  <ul>
  <li>Field length always <em>9</em> numeric digits.</li>
  <li>Can not be all same digits (e.g. <code>222-22-2222</code>)</li>
  <li>Can not contain continuous, sequential numbers from <code>1 to 9</code> or <code>9 to 1</code> (i.e. <code>123-45-6789</code>, <code>9876-54-321</code>)</li>
  <li>Can not contain data other than numerical digits (<code>0-9</code>)</li>
  <li>Restricted numbers beginning with <code>666</code>, <code>000</code>.</li>
  <li>Can not contain 9 as the first number.`</li>
  <li>Last four digits can not be zeros <code>(0000)</code>.</li>
  </ul>