Search code examples
htmluser-interfacegwtuibinder

Get HTML elements in GWT


Like there is a getElementById() in JavaScript to get a HTML tag and in Android to attach to UI Element , is there a way in GWT do all the stylings in basic HTML and CSS and just use GWT for event handling ?

In other words, If I have in HTML :

<input type="button" id="refresh">

And in GWT :

Button b1 = new Button();

Can I bind these two together ?

~Thanks


Solution

  • Got the right answer :-

    Button button = Button.wrap(Document.get().getElementById("submit"));
    

    is working for me.