title: Getting the value of a variable from localStorage from a different javascript file
body: <p>having a problem using localstorage in javascript. 
  I have two javascript files and one multi-page html file. I'm setting the value of a variable to store in local storage in the home.js class and I then want to get the value of the same variable in my editCase.js class. Is this possible? The goal here is to use the variable several places in the html file.</p>
  
  <p>home.js: </p>
  
  <pre><code>var _NSCaseId;
  var nsId;
  $("#listOfCases li").click(function(){
              nsId = $(this).attr('id');
              LocalStorage.save(_NSCaseId, nsId);
              alert(nsId);
          });
  </code></pre>
  
  <p>As you can see, the value is the id of a listview item. This works fine and the alert shows the correct value every time.</p>
  
  <p>I then want to use the same variable in the editCase.js file:</p>
  
  <pre><code>var id = LocalStorage.get(_NSCaseId);
      alert(id);
  </code></pre>
  
  <p>But I get an error in logcat saying _NSCaseId is undefined in editCase.js</p>
  
  <p>Any suggestions?</p>