+ Reply to Thread
Results 1 to 5 of 5

force input data to be uppercase

  1. #1
    Registered User
    Join Date
    11-16-2007
    Posts
    5

    force input data to be uppercase

    Hello,
    I need to enter surnames in a column and they all have to be recorded in uppercase. Is there any way I can enforce this condition ? I'm trying to apply the UPPER function to the column but with no success. I could not find a validation criteria that matches what I want, as well.

    Thanks for the help,
    Abraham

  2. #2
    Forum Expert
    Join Date
    12-29-2004
    Location
    Michigan, USA
    MS-Off Ver
    2013
    Posts
    2,208
    An easy way to do this is with VBA.

    Right-click on the sheet tab, select View Code, and copy the following procedure:
    Please Login or Register  to view this content.
    If you are using a column other than A, just change the column reference above. This will not require the user to enter upper case; rather, it will automatically change it to upper case.

    HTH

    Jason

  3. #3
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    force input data to be uppercase

    Try this example:

    Select A1:A10, with A1 as the active cell

    Then....from the Excel Main Menu:
    <data><validation>
    Allow: Custom
    Formula: =EXACT(A1,UPPER(A1))
    Click [OK]

    Is that something you can work with?
    Ron
    Former Microsoft MVP - Excel (2006 - 2015)
    Click here to see the Forum Rules

  4. #4
    Registered User
    Join Date
    11-16-2007
    Posts
    5
    Not sure I did it right, Ron, but it did not work for me.
    Thanks Jason, that's exactly what I needed.

    Good to know this things are achievable through VB, I thought I could get along with the functions itself. Time to start learning some VB.

    Thanks !

  5. #5
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689
    The advantage of Ron's method is that it does not use VBA to modify the sheet contents, which flushes the Undo buffer. From that perspective, it would be worth trying again.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1