Type Error in javascript
<p>I am very new to programing.. Like the title says I am getting a Type Error..</p>

<pre><code>function buttonClicked(userInput){
  var app = UiApp.getActiveApplication();
  var nmeOne = app.getElementById('txtNmeOne').value;
  var nmeTwo = app.getElementById('txtNmeTwo').value;
  var lengNameOne = (nmeOne.length);
  var lengNameTwo = (nmeTwo.length);
  var whole = lengNameOne + lengNameTwo;
  var percent = lengNameOne / whole;
  var tOneHun = percent * 100;
  app.getElementById('lblResult').setText("The Compatibility Percentage Is: " + tOneHun + "%");
  return app;
}
</code></pre>
