Results 1 to 4 of 4

How to force LEFT function to recognize a number?

Threaded View

  1. #1
    Forum Contributor
    Join Date
    07-28-2009
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    99

    How to force LEFT function to recognize a number?

    Basically I have a phone number in column A:

    123-456-1234

    In column B, I want it to show me the first 3 numbers from the left, (so 123)

    So I do =LEFT(A2,3)

    Which gives me 123, but it's displayed as text, which ruins my whole formula that looks up the area code and displays the state.

    I googled the problem and found http://exceltip.com/st/Make_LEFT_Fun...umber/778.html

    which tells me to do:
    =IF(LEFT(A1,1)=1,"Ignore",A1) [sees 1 as a number]
    =IF(LEFT(A1,1)+0=1,"Ignore",A1) [sees 1 as a number]
    =IF(LEFT(A1,1)="1","Ignore",A1) [sees 1 as text]

    but when i try that it just displays the ENTIRE phone number: 123-456-1234

    i only want the first 3.. any ideas?
    Last edited by Tommy1005; 07-29-2009 at 11:34 AM.

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