Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Other Java > Java GUI
|
Java GUI Discussions specific to programming Java GUI.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Java GUI section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old September 26th, 2005, 03:10 PM
Authorized User
 
Join Date: Mar 2005
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Restrict # of input Char. to TextFiled/ComboBox

Hi to all,

Is anyone has a general "Utility" class codes for the purpose of limiting (or restricting) the number of characters can be entered into a JTextfield and/or JComboBox? In other words when the user enteres up to the maximum allowed number of characters into either JTexField or JComboBox, no more characters is accepted by that "entry field".

Thanks in advance.

 
Old February 1st, 2006, 05:38 AM
Authorized User
 
Join Date: Oct 2005
Posts: 72
Thanks: 0
Thanked 0 Times in 0 Posts
Default

we'll i don't have one but i think you can implement it.
just play around with the itemeventlistener. =D

 
Old February 7th, 2006, 12:27 AM
Authorized User
 
Join Date: Aug 2005
Posts: 18
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You can use JFormattedTextField,
Look at this post,

http://www.javareference.com/mvnforu...ead?thread=347

Rahul

[email protected]
--------------------------
http://www.javareference.com





Similar Threads
Thread Thread Starter Forum Replies Last Post
Big challenge here! How to convert char* to char^? samiswt Visual C++ 2005 1 November 30th, 2007 09:09 PM
Invalid conversion from 'char*' to 'char' deuxmio C++ Programming 3 December 8th, 2006 07:56 AM
Restrict elements guozhang XML 0 April 28th, 2004 02:26 PM
how to restrict strings with particular characters srini XSLT 6 November 28th, 2003 07:03 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.