textfield to take only numnbers
I s there any textfield which takes only numbers, I dont want user to enter letters only numbers so I want a textfield which takes only numbers is there any such textfield ? -- View this message in context: http://www.nabble.com/textfield-to--take-only-numnbers-tp21729554p21729554.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: textfield to take only numnbers
Hi Miro, can't you use a PatternValidator such as: add(new TextField(textfieldname).add(new PatternValidator(^\\d+$))); Cheers Philipp I s there any textfield which takes only numbers, I dont want user to enter letters only numbers so I want a textfield which takes only numbers is there any such textfield ? -- Averbis GmbH c/o Klinikum der Albert-Ludwigs-Universität Stefan-Meier-Strasse 26 D-79104 Freiburg Fon: +49 (0) 761 - 203 6707 Fax: +49 (0) 761 - 203 6800 E-Mail: dau...@averbis.de Geschäftsführer: Dr. med. Philipp Daumke, Kornél Markó Sitz der Gesellschaft: Freiburg i. Br. AG Freiburg i. Br., HRB 701080 - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
RE: textfield to take only numnbers
Pass the field type in the TextField's constructor http://wicketstuff.org/wicket13/compref/?wicket:bookmarkablePage=:org.apache.wicket.examples.compref.TextFieldPage -Heikki -Original Message- From: miro [mailto:miroconn...@yahoo.com] Sent: 29. tammikuuta 2009 17:52 To: users@wicket.apache.org Subject: textfield to take only numnbers I s there any textfield which takes only numbers, I dont want user to enter letters only numbers so I want a textfield which takes only numbers is there any such textfield ? -- View this message in context: http://www.nabble.com/textfield-to--take-only-numnbers-tp21729554p21729554.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: textfield to take only numnbers
new TextFieldInteger(id); new TextField(id, Integer.class); new TextFieldInteger(id, Integer.class); On Thu, Jan 29, 2009 at 9:52 AM, miro miroconn...@yahoo.com wrote: I s there any textfield which takes only numbers, I dont want user to enter letters only numbers so I want a textfield which takes only numbers is there any such textfield ? -- View this message in context: http://www.nabble.com/textfield-to--take-only-numnbers-tp21729554p21729554.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Jeremy Thomerson http://www.wickettraining.com