title: Can't get jqgrid addRowData to work
body: <p>First off, I want to make it clear that I know there are other posts quite similar to mine in these forums. Unfortunately, using them I have failed to get addRowData to work.  I have a table that is defined like this:</p>
  
  <pre><code>var tableDef = {
          scroll: 1,
          url:"/SCSalesDataReport/showReport/getSalesReportJSON",
          datatype: "json",
          colNames:['id','Type', 'Name', 'Total','In','Out'],
          colModel:[
              { name: 'id', index: 'testid', hidden: true},     
              {name:'type',index:'type', width:10, sortable:true},
              {name:'name',index:'name', width:40, sortable:true},
              {name:'total',index:'total', width: 10, sortable:false},
              {name:'in',index:'in', width:10, sortable:true},
              {name:'out',index:'out', width:10, sortable:true}, ],
          rowNum:100,
          mtype: "GET",
          sortname: 'id',  
          viewrecords: true,
          height : '500',
          altRows: true,
          autowidth: true,
  };
  </code></pre>
  
  <p>and for what it is worth, that is working and populating the table as one would expect.  Unfortunately, using some of the posts I've seen in these forums, I can't add data to the table once it has been created.  I'm trying to add a row via a link, like this:</p>
  
  <pre><code>window.onload = function() {
  
      var a = document.getElementById("addRow");
      a.onclick = function() {
          var count = $("#grid").getGridParam("reccount");
          var newRowData = {'id':count, 'Type':"ADDEDTYPE", 'Name':"Insert 1", 'Total':"10",'In':"50",'Out':"40"}; 
          jQuery("#myTable").addRowData("id", newRowData);
          jQuery("#myTable").trigger("reloadGrid");
  
        return false;
      }
   }
  </code></pre>
  
  <p>which is connected to this tag:</p>
  
  <pre><code>&lt;a id="addRow" href="www.google.com"&gt;Oh please, for the love of all that is holy... add a row!&lt;/a&gt;
  </code></pre>
  
  <p>If someone could help me figure out what I'm doing wrong, that would be <em>greatly</em> appreciated.  I strongly suspect I'm just doing something dumb, or overlooking something simple.</p>
  
  <p>Thanks in advance.</p>