title: How to call Java method on button created in JS/JSNI
body: <p>I want to call a Java method on a click of a button which is NOT created as usual in GWT but is created by using plain HTML.</p>
  
  <p>Below is the sample code:-</p>
  
  <pre><code>private native void createHeaderSpanContents(Element element)/*-{
  
  element.innerHTML='&lt;button type="button" onclick="this.@ca.bell.nis.psp.client.gui.AbstractSearchResultGrid::hideColumns()()"&gt;&lt;/button&gt;Identification';
  </code></pre>
  
  <p>}-*/;</p>
  
  <pre><code>public void hideColumns() {
      // Hide the columns
  }
  </code></pre>
  
  <p>The above way of calling hideColumns() Java method from within JSNI does not work here. Please help!</p>
  
  <p>Regards,
  -Trans. </p>