using static hetml text input as datebox in gwt

68 views
Skip to first unread message

HDayi

unread,
May 2, 2012, 9:54:11 AM5/2/12
to google-we...@googlegroups.com
hi people,
i hope i could mean myself.
in my html file there is a textbox written in classical html tag like:
<input id="date" type="text" maxlength="10" />
how can i use it as a text box?

thx

Milan Cvejic

unread,
May 3, 2012, 9:08:49 AM5/3/12
to google-we...@googlegroups.com
Hi,
you can try something like

Element textElement = DOM.getElementById("date");
TextBox textBox = TextBox.wrap(textElement);

later you can use textBox as any other TextBox widget.

I haven't tried this but it should work.

Cheers,
Milan Cvejic
Reply all
Reply to author
Forward
0 new messages