+ Reply to Thread
Results 1 to 6 of 6

to extract second character from a cell

  1. #1
    Registered User
    Join Date
    12-22-2010
    Location
    Hong Kong
    MS-Off Ver
    2013
    Posts
    74

    to extract second character from a cell

    Hi

    I would like to extract only a second character from a cell on the left. What formula is for this purpose?

    Thanks
    Last edited by Harrold; 09-02-2011 at 03:08 AM.

  2. #2
    Forum Expert
    Join Date
    07-16-2010
    Location
    Northumberland, UK
    MS-Off Ver
    Excel 2007 (home), Excel 2010 (work)
    Posts
    3,054

    Re: to extract second character from a cell

    If your data is in, say, cell A1 then in another cell put the formula =MID(A1,2,1)

  3. #3
    Registered User
    Join Date
    12-22-2010
    Location
    Hong Kong
    MS-Off Ver
    2013
    Posts
    74

    Re: to extract second character from a cell

    Hi Andrew,

    Thanks for your prompt reply.

    It works with a minor issue. The formula does not detect '0' when it is the first character. Say, 0123, your formula for the 1st character is 1 instead of 0.

    Is there a way to resolve it?

    Thanks again

  4. #4
    Forum Expert
    Join Date
    07-16-2010
    Location
    Northumberland, UK
    MS-Off Ver
    Excel 2007 (home), Excel 2010 (work)
    Posts
    3,054

    Re: to extract second character from a cell

    I'm not entirely sure I understand.

    Either:

    a) Your data is the string '0123', in which case the 2nd character is 1, but you want to ignore the zero and return 2 as the 2nd character or

    b) Your data is 123, but formatted to 4 digits with a leading zero, in which case my formula will return '2', but you actually want it to return '1'.

    Let me know which it is and I'll sort it for you.

    Thanks,

    Andrew

  5. #5
    Registered User
    Join Date
    12-22-2010
    Location
    Hong Kong
    MS-Off Ver
    2013
    Posts
    74

    Re: to extract second character from a cell

    Hi Andrew,

    Option b please.

    Thanks

  6. #6
    Forum Expert
    Join Date
    07-16-2010
    Location
    Northumberland, UK
    MS-Off Ver
    Excel 2007 (home), Excel 2010 (work)
    Posts
    3,054

    Re: to extract second character from a cell

    Oh good, that's the easy one.

    Again with the data in cell A1, the formula is =MID(TEXT(A1,"0000"),2,1)

+ 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