title: How to add rows to a GXT grid
body: <p>I'm trying to create a fairly simply GWT app using the GXT framework, and am doing this based on the eBook "Ext GWT 2.0 Beginners Guide". It details all the step for building an app using GXTs MVC model, and most of it is working as expected, however I can not - for the life of it - add new rows to my Grid. </p>
  
  <p>The initial loading of the Grid data (through itemStore, loader, and an RPCProxy work correct).</p>
  
  <p>However every time I fire the event that triggers adding a new row, the ListStore to which I want to add, is empty (not null! but empty) - even though my Grid is showing data after the initial load!</p>
  
  <p>Here is some of the relevant code:</p>
  
  <pre><code>public class MessageGrid extends LayoutContainer {
      private final Grid&lt;ModelData&gt; grid;
      private final ListLoader&lt;ListLoadResult&lt;MarketingMessage&gt;&gt; loader;
      private final ListStore&lt;ModelData&gt; itemStore;
      public MessageGrid() {
          setLayout(new FitLayout());
          final MarketingServiceAsync marketingService = Registry.get(MarketingUIConstants.MARKETING_SERVICE);
          RpcProxy&lt;List&lt;MarketingMessage&gt;&gt; proxy = new RpcProxy&lt;List&lt;MarketingMessage&gt;&gt;() {
              @Override
              protected void load(Object loadConfig, final AsyncCallback&lt;List&lt;MarketingMessage&gt;&gt; callback) {
                  marketingService.getMessages(callback);
              }
          };
          final List&lt;ColumnConfig&gt; columns = new ArrayList&lt;ColumnConfig&gt;();
          columns.add(new ColumnConfig("col1", "Name", 100));
          columns.add(new ColumnConfig("col2", "Phone", 100));
          final ColumnModel columnModel = new ColumnModel(columns);       
          loader = new BaseListLoader&lt;ListLoadResult&lt;MarketingMessage&gt;&gt;(proxy);
          itemStore = new ListStore&lt;ModelData&gt;(loader);
          grid = new Grid&lt;ModelData&gt;(itemStore, columnModel);
          grid.setBorders(true);
          grid.setAutoExpandColumn("sentTime");
          grid.setAutoHeight(false);
          grid.setHeight("100%");     
      }
  
      @Override
      protected void onRender(Element parent, int index) {
          super.onRender(parent, index);
          loader.load();
          add(grid);
      }
  
      public void addMessage(MarketingMessage marketingMessage) {
          itemStore.add(new MarketingMessage("test", "test")));
      }
  }
  </code></pre>
  
  <p>addMessage() is being called by the owning component (a View to which this LayoutContainer has been added).</p>
  
  <p>If I set a breakpoint inside the addMessage() method, my itemStore has size 0 (same goes for grid.getStore() for that matter).</p>
  
  <p>I've tried various different changes to this code and I have yet to see a row being added.</p>
  
  <p>On a similar note: if inside the addMessage() method I try to do a reload from the proxy - since I do update the server side data as well - ie. loader.load(), it <em>also</em> does not have any visible effect. </p>