title: String length validation in javascript
body: <p>I have a small problem with a task I've been asigned. I'm trying to make an alert message appear if the length of the inputted number does not equal 7. The message appears even if the length of the number is equal to 7 and I can't figure out why, any help would be appreciated! thanks.</p>
  
  <pre><code>var msg = "";
  
  if (document.Entry.Number.length!== 7) {
              msg+="Your Number should be 7 digits. Please check this. \n";
              document.Entry.Number.focus();
              document.getElementById('Number').style.color="red";
              result = false;
          }
          if(msg==""){
              return result;
          }
  
          {
              alert(msg)
              return result;
          }
  </code></pre>