title: populate grid with temp table from click event handler d365fo
body: <p>I am trying to populate a <code>grid</code> form with a <code>temp table</code> (inMemory) from a click event handler but the <code>grid</code> isn't populate. here is my code:</p>
  <pre><code>class ARQ_CONCCo_InventTransRegisterFormEvents
  {
  
  [FormControlEventHandler(formControlStr(InventTransRegister, ARQImportCSV), FormControlEventType::Clicked)]
  public static void ARQImportCSV_OnClicked(FormControl sender, FormControlEventArgs e)
  {
      TmpInventTransWMS   inventTransWMS, inventTransWMSAux;
      FormDataSource      inventTransWMS_ds;
      FormRun             formRun = sender.formRun() as formRun;
  
      inventTransWMS_ds = sender.formRun().dataSource(formDataSourceStr(InventTransRegister, TmpInventTransWMS)) as FormDataSource;
      inventTransWMSAux = inventTransWMS_ds.cursor();
  
      inventTransWMS.InventQty    = 10.00;
      inventTransWMS.UnitId       = &quot;KG&quot;;
  
      inventTransWMS.insert();
  
      inventTransWMSAux.setTmpData(inventTransWMS);
  }
  
  }
  </code></pre>