Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Java
How to allow only two letters in square bracket in java
Eg : [AB] like this i need to give .
Posted 28-Sep-12 20:41pm
Comments
Sergey Alexandrovich Kryukov at 29-Sep-12 1:42am
   
Allow... for who? :-)
--SA

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Assuming that you want to be able to introduce only a [@@] (where @@ are two letters) inside an edit box. is that right?
 
Take a look at those links: http://www.devdaily.com/java/jwarehouse/eclipse/org.eclipse.jface.examples.databinding/src/org/eclipse/jface/examples/databinding/mask/EditMask.java.shtml[^]
http://www.java2s.com/Tutorial/Java/0240__Swing/FormattedMaskedInputnewMaskFormatter.htm[^]
http://www.java2s.com/Code/Java/Swing-JFC/JFormattedTextFieldaninputmaskforatelephonenumber.htm[^]
 
You are interested on searching for a "INPUT MASK" or "EDIT MASK".
 
Good luck!
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Maciej Los 515
1 OriginalGriff 450
2 CHill60 305
3 Abhinav S 300
4 Sergey Alexandrovich Kryukov 294
0 Sergey Alexandrovich Kryukov 9,897
1 OriginalGriff 9,395
2 Peter Leow 5,162
3 Kornfeld Eliyahu Peter 3,373
4 Maciej Los 3,036


Advertise | Privacy | Mobile
Web04 | 2.8.150327.1 | Last Updated 29 Sep 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100