+ Reply to Thread
Results 1 to 5 of 5

Data validation - numbers as text

Hybrid View

  1. #1
    Registered User
    Join Date
    09-07-2011
    Location
    London, UK
    MS-Off Ver
    Excel 2007
    Posts
    38

    Data validation - numbers as text

    Dear Fellas,

    I would very much appreciate your help on the following:

    Would anyone know how to enable data validation in order to enforce putting numbers as texts. So I want user to only be able to input '123123 and not 123123.

    I was thinking 'custom' in 'data validation' and I have tried formula = " ' " & " * " [no spaces].

    If you have any suggestions please let us know.

    ps. Where this is used? I have a sumproduct function that validates certain values and it is not working if values are values and not texts (=sumproduct(A1:A10,--(B1:B10=C1)), where C1 is ['123123].

    Cheers!

  2. #2
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Data validation - numbers as text

    Why not just format cell as TEXT?
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

  3. #3
    Registered User
    Join Date
    01-23-2014
    Location
    Romania
    MS-Off Ver
    Excel 2016
    Posts
    54

    Re: Data validation - numbers as text

    You can choose Allow:Custom and try this formula: =ISTEXT(A2)=TRUE

  4. #4
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Data validation - numbers as text

    You can make the adjustment in the formula..
    Quote Originally Posted by gutkinma View Post
    I have a sumproduct function that validates certain values and it is not working if values are values and not texts (=sumproduct(A1:A10,--(B1:B10=C1)), where C1 is ['123123].

    Cheers!
    =sumproduct(A1:A10,--(B1:B10&""=C1))
    or
    =sumproduct(A1:A10,--(B1:B10=C1+0))

  5. #5
    Registered User
    Join Date
    09-07-2011
    Location
    London, UK
    MS-Off Ver
    Excel 2007
    Posts
    38

    Re: Data validation - numbers as text

    Thank you all,

    AlKey - good call, but I want a fool-proof solution.

    tchock, Jonmo1 - thanks, all works perfectly.

    Many thanks!!!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Custom Data Validation That Evaluates for Numbers AND Text
    By jpdawson in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-18-2013, 05:05 PM
  2. [SOLVED] Data validation combo box, numbers formatted as text
    By Folshot in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 12-27-2012, 11:09 AM
  3. Excel 2007 : Data validation with numbers and text
    By madams_08 in forum Excel General
    Replies: 3
    Last Post: 12-06-2012, 03:37 PM
  4. [SOLVED] Data validation with numbers stored as text broken
    By MrsAlice in forum Excel General
    Replies: 3
    Last Post: 10-19-2012, 12:28 AM
  5. Data Validation Numbers and Text
    By DWW in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-06-2005, 02:05 PM

Tags for this Thread

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