+ Reply to Thread
Results 1 to 5 of 5

Converting data in a cell.

  1. #1
    Forum Contributor
    Join Date
    09-03-2004
    Location
    Vancouver, BC Canada
    Posts
    136

    Converting data in a cell.

    Hi there,
    In the attached sheet I have an account # in a cell that is as follows:

    625112-01-2-000-0506
    I need to remove the hyphens and have a single # in the cell. I have tried converting it using "Text to columns" and then adding them together ( Using & or concatenate) but I'm running into a problem. As soon as I convert I lost the "0"s. For example:
    The second column become 1 instead of 01
    the 4th column loses the multiple 0s and returns a singe 0
    the 5th column return only 506.

    Could some one help me please? Thanks a bunch for looking into it!

    Thanks,
    SJ
    Attached Files Attached Files

  2. #2
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Converting data in a cell.

    I didn't download your file.

    See if this works for you...

    A1 = 625112-01-2-000-0506

    This formula in B1:

    =SUBSTITUTE(A1,"-","")

    That will return 6251120120000506 as a TEXT value.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  3. #3
    Registered User
    Join Date
    02-24-2016
    Location
    The Netherlands
    MS-Off Ver
    365
    Posts
    92

    Re: Converting data in a cell.

    Hi,

    You can try in a free cell:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Click on Add Reputation below please is this helps.
    WouterM
    The Netherlands

  4. #4
    Forum Contributor
    Join Date
    09-03-2004
    Location
    Vancouver, BC Canada
    Posts
    136

    Re: Converting data in a cell.

    Thanks Sir.
    It worked!

  5. #5
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Converting data in a cell.

    You're welcome. Thanks for the feedback!

+ 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. Auto-Converting Cell Value to link & moving rows of data based on cell value
    By Th3Forgotten in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-15-2013, 08:05 AM
  2. Converting multiple columns to rows / Converting to Panel Data
    By Stuart11 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-14-2013, 05:50 AM
  3. Replies: 5
    Last Post: 09-11-2012, 03:45 PM
  4. Replies: 2
    Last Post: 01-15-2012, 02:05 PM
  5. Replies: 5
    Last Post: 04-23-2010, 08:01 AM
  6. Converting data in one cell to 3 different cells
    By Steve in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 07-12-2006, 09:05 AM
  7. Prevent cell data from converting to euros
    By mcdonobr in forum Excel General
    Replies: 1
    Last Post: 04-22-2006, 03:45 PM

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