Only A-Z letters

hi, i've got class:
class UpperCaseField extends JTextField {
     public UpperCaseField(int cols) {
         super(cols);
     protected Document createDefaultModel() {
         return new UpperCaseDocument();
     static class UpperCaseDocument extends PlainDocument {
         public void insertString(int offs, String str, AttributeSet a)
             throws BadLocationException {
             if (str == null) {
                 return;
             char[] upper = str.toCharArray();
             for (int i = 0; i < upper.length; i++) {
                 upper[i] = Character.toUpperCase(upper);
super.insertString(offs, new String(upper), a);
i took it from help file.
But i want add something else: i want to do that user can to type only letters from range A-Z (without digits, special signs for examlpe "/,. '...");
how can i do that?
thud
null

ok, i add that method to my class:
    protected MaskFormatter createFormatter(String s) {
        MaskFormatter formatter = null;
        try {
            formatter = new MaskFormatter(s);
        } catch (java.text.ParseException exc) {
            System.err.println("formatter is bad: " + exc.getMessage());
            System.exit(-1);
        return formatter;
    }and then:
        JFormattedText Field keyField = new JFormattedTextField(createFormatter("UUUUU"));
        keyField.setColumns(27);and it works well :), but...
the numbers of "UUUUU" means how many letters could user type. But i want that the user could type 1024 characters, so how can i do that??
I don't wanna write "UUUUUUUUUUUUU..."-1024-times :/; Is there another way to do this??
null

Similar Messages

  • Can only see 3 letters in Description and label boxes

    Captivate 5.5 only allows 3 letters to be seen in the "item name" textbox in the properties window. I am working in MAC OS 10.5.8. When I try to enter an the name of an item in the item name textbox in the properties window, it only allows the first 3 letters to be seen. Although the text I type in the box is all there.

    Hello,
    Bit confused, due to terminology, but could you post a screenshot of the properties panel where you only see 3 characters? Are you pointing to this:
    If that is the case, seems something is corrupted in Captivate, never saw this issue mentioned in the forums up till now. Try first to clear the cache (Preferences, General), and eventually to clear the Preferences while CP is closed. Those preferences are the folder Adobe Captivate 5.5 you'll find here:
    Mac:  /Users/[user name]/Library/Preferences/Adobe Captivate 5 folder
    Lilybiri

  • Why is my keyboard only typint CAPITAL LETTERS?

    My keyboard only types CAPITAL LETTERS. When I restart the computer it is taking ages to boot and words "Boot Safe" appears in red on the screen. Mail search is not working and nor is spotlight

    vicentelou,
    if you made a backup of your system before installing 10.9.4, you can restore from the backup. If you didn’t make such a backup, you can do it manually by booting into Recovery mode, completely erasing your internal disk, letting OS X Internet Recovery redownload and reïnstall your MacBook Pro’s original version of OS X, running Software Update to get it up to date in-version, and if necessary redownloading Mavericks from the Mac App Store and reïnstalling Mavericks — that should get you back to 10.9.3.

  • My product code only has 22 letters & numbers but I need 24 to redeem it and install. What should I do?

    I need a 24-alphanumeric code to redeem my serial number and install photoshop but the code on my box only has 22 letters and numbers. I don't know what to do.

    Redemption codes are rarely on the box. See if this helps any:
    Redemption Code Help

  • HT1918 I'm from the Philippines and the County field does not accept 3 letters. Not sure why when the drop down options only has 3 letters for the provinces.

    The Philippines only has Provinces not Counties and the province initials only have 3 letters. I cannot create my Apple ID because it keeps getting the "enter at least 4 letters or numbers" error. Please help.

    kodemage wrote:
    well, then recovery mode does not work. I've tried all the key combinations I've seen on line. Command+R, Command+Option+R, Command+Option+P+R, none of these work.
    I don't believe there is anything we can do on a forum to help then, you need to take it into a AASP and have it professionaly diagnosed. If you don't know how to locate an AASP in your area you can begin by using Contact Apple for support and service
    Good luck.

  • TS1398 My wireless password in only 6 lowercase letters, but my iPod touch requires me to enter 8 before allowing me to join.  Therefore it will not let me log on to the wireless network, any solutions?

    My wireless password in only 6 lowercase letters, but my iPod touch requires me to enter 8 before allowing me to join.  Therefore it will not let me log on to the wireless network, any solutions?

    What encryption are you using on the router?
    If WEP you have to set the router to use the first key and you have to enter the first key as the password on the iPod. See:
    iOS: Recommended settings for Wi-Fi routers and access points

  • Table entries only with capital letters

    Hi
    I have created a table with some entries.One of these is type char length 65.My problem appears when i try to add entries to my table in this field,it will automatically transform them in capital letters.Even if i write with small letters,when saving,it will save my text with capital letters.How can i change this?
    thank you.

    Hi Seba,
    Make below change in the DOMAIN for that field
    Domain
    Defination Tab
    Tick Lower Case Checkbox of Output Characteristics..
    Use
    When this attribute is activated, you can enter both upper and lower
    case letters; conversion to upper case does not then take place. Use of
    this attribute only makes sense with character formats.
    Hope it will solve your problem..
    Thanks & Regards
    ilesh 24x7
    ilesh Nandaniya

  • My keyboard only types certain letters

    on my password screen, my usb keyboard (razer blackwidow 2013) won't type certain letters so i can't login in. for example, my password is mattman23 and i can only type the the letter "t" and "23". i have tried a logitech wireless keyboard and still the exact letters don't type. i downloaded os x yosemite last night. today my computer died and when i turned it on this happened. i have a 2011 edition macbook pro. please help

    You can try resetting the SMC and PRAM.
    Intel-based Macs: Resetting the System Management Controller (SMC)
    About NVRAM and PRAM
    However, I suspect that the milk is causing some keys to show full or partial pressing and that is interfering with signals from other key pressings.
    I suspect yo need to to clean/replace the internal KB
    Try fixing it yourself
    https://www.ifixit.com/Device/MacBook_Pro
    - Make an appointment at the Genius Bar of an Apple store and hear what they have to say.
      Apple Retail Store - Genius Bar

  • Open Invoices Only in Dunning Letters

    Hello All,
    I am currently updating AR proceedures and part of that is to issue reminder letters.  I am using the dunning wizard to do this.  In the letter i wish to display any overdue invoices for payment.
    I have no troubles in getting all of the open invoices for a BP onto the dunning letter, however, i only want to include the invoices that are over due.  All customer payment terms are 30 days. 
    If you need any more information please let me know
    Thanks

    Thanks Gordon,
    There is actually an open items tick box as well as a due date field in the dunning wizard.  I didnt notice them before.  fixed the problem.
    I have actually now found a different issue with the same report though.
    When i print the letter i get multiples of the one invoice
    ie
    dear sir,
    this is over due
    inv 456 $5
    inv 456 $5
    inv 456 $5
    inv 456 $5
    inv 456 $5
    Total due $5
    Thanks
    Accounts
    I have just compared it to the system letter template and the fields do not differ from what i can see.  (i also checked for check boxes and entry field in the wizard, all the same)

  • My PSE12 will only type CAPITAL letters no matter what font I choose.  Started doing this yesterday

    My PSE12
    will only type CAPITAL letter no matter what font I choose.  Started doing this yesterday and I can't get back to having upper and lower case letters.

    Perhaps you could reset the tools using this method:
    1) Launch PSE in Editor Mode
    2) click on the Expert Tab
    3) At the bottom right corner look for something like this :
    This should solve the problem quickly.
    Good luck and post back.

  • Mx459 will not let me enter number in WEP key, only allows symbols/letters. how do i enter numbers?

    mx459 will not let me enter number in WEP key, in only allows symbols or letters. how do i enter numbers?
    john
    Solved!
    Go to Solution.

    This might help
    Press the SETUP button on your printer's control panel.
    Using the arrows, select DEVICE SETTINGS, press OK.
    Select LAN SETTINGS and press OK.
    Select Wireless LAN Setup and press OK.
    If a message appears to press the WPS button, press STOP to cancel.
    Select STANDARD SETUP from the next screen that appears and press OK.
    Highlight your access point or router and press OK.
    Press OK again to confirm the access point name.
    Enter your passphrase using the keypad to the right.
    At the screen where you enter your passphrase, in the top right corner of the LCD screen you should see a :1 . This indicates that you are in numeric entry mode. If you press the asterisk key (*) it will switch to :A or uppercase letter mode, pressing asterisk again with switch to lowercase letter mode. To enter a letter in either letter mode, you will press the associated number key to cycle through the available letters. For example: To enter a letter "c", you will press the "2" key three times.
    Press OK when done.
    The LCD screen will say "Connected" if the password is correct.
    John Hoffman
    Conway, NH
    1D Mark IV, Rebel T5i, Pixma PRO-100, MX472

  • My backed up files from iphone to my mac cannot be seen as they are, but only numbers and letters, they seem to be encrypted even though I did not click on encrypted when backing up

    I am using a Mac Book Air to back up my Iphone 5 on Itunes. What I can see of the files are encrypted even though I did not click on the Encrypt box.
    Please, help.

    Backups of an iPhone made using iTunes are stored in a format that is only meant for use in a restore and are not meant to be accessed directly. There are other methods of transferring things like photos and contacts to your computer such as iOS: Import personal photos and videos from iOS devices to your computer, iCloud: My Photo Stream FAQ, and https://www.apple.com/icloud/
    If you absolutely must directly access an iTunes backup there is 3rd party extraction software available such as http://www.wideanglesoftware.com/ibackupextractor/

  • I want to make a purchase in apple store but they ask me to have 3letters in the name of my county (select province). All choices are only 2 letters like KL,SL... I don't know how can I do. Please

    I want to make a purchase in apple store but they ask me to have 3letters in the name of my county (select province). All choices are only in 2 letters like KL,SL... I don't know how can I do. Please

    What country did you specify?

  • When using Edit Find, I can only type 3 or 4 letters in the Find bar before the letters start disappearing. If I copy/paste a word into the Find bar all the letters will be there. Has anyone else had this problem?

    The Find bar opens OK with Edit/Find. I start typing in a word there but it will only allow 3 letters before they disappear and my next keystroke appears. I can copy/paste a whole word or string of words into the Find bar and all the letters remain.
    == This happened ==
    Every time Firefox opened
    == about a month ago

    See [[Troubleshooting extensions and themes]] and [[Troubleshooting plugins]]
    If it does work in Safe-mode then disable all your extensions and then try to find which is causing it by enabling one at a time until the problem reappears.
    You can use "Disable all add-ons" on the [[Safe mode]] start window to disable all extensions.
    You have to close and restart Firefox after each change via "File > Exit" (Mac: "Firefox > Quit"; Linux: "File > Quit")

  • I purchased an IPAD2 for my special needs daughter.  She only currently understands lowercase letters only and gets confused with the uppercase letters.  Is there a way to change the keyboard to display lowercase letters?

    I purchased an IPAD2 for my special needs daughter.  She only currently understands lowercase letters only and gets confused with the uppercase letters.  Is there a way to change the keyboard to display lowercase letters?

    There is no way for the keyboard itself to display only lower case letters. It doesn't display lower case letters at all for that matter.
    When you are using the keyboard - The other issue that you will have is with the shift key. Even with auto caps turned off you can still type capital letters if you tap the shift key and if you double tap it by mistake - it will turn into all capital letters so also turn off Caps Lock in the keyboard settings.
    Other than that, there is no way to ensure that you can type in lower case.
    Maybe an external bluetooth keyboard would be a better solution but I don't use one, and I have never even seen one in person so someone else will have to verify that for you.

Maybe you are looking for