+ Reply to Thread
Results 1 to 8 of 8

Delete only some of a cells contents

  1. #1
    Registered User
    Join Date
    11-02-2011
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2010
    Posts
    52

    Delete only some of a cells contents

    I need some script to only delete the first few letters of a cells contents and leave the rest. I have done searches and cant find anything please help.

    Example) cell contains: Test 2014

    I want to delete the word "Test " and the space after it leaving only 2014.

    Thanks.

  2. #2
    Forum Expert judgeh59's Avatar
    Join Date
    02-07-2013
    Location
    Boise, Idaho
    MS-Off Ver
    Excel 2016
    Posts
    2,310

    Re: Delete only some of a cells contents

    is it always after the first space or does the criteria change?....
    Ernest

    Please consider adding a * if I helped

    Nothing drives me crazy - I'm always close enough to walk....

  3. #3
    Registered User
    Join Date
    11-02-2011
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2010
    Posts
    52

    Re: Delete only some of a cells contents

    To clear this up I need to delete everything before the first space and delete everything after the second space. Just return the data between the two spaces

  4. #4
    Forum Expert judgeh59's Avatar
    Join Date
    02-07-2013
    Location
    Boise, Idaho
    MS-Off Ver
    Excel 2016
    Posts
    2,310

    Re: Delete only some of a cells contents

    give this a try

    Please Login or Register  to view this content.

  5. #5
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Delete only some of a cells contents

    FWIW:

    Please Login or Register  to view this content.

  6. #6
    Forum Expert judgeh59's Avatar
    Join Date
    02-07-2013
    Location
    Boise, Idaho
    MS-Off Ver
    Excel 2016
    Posts
    2,310

    Re: Delete only some of a cells contents

    so, did either of these 2 solutions help?

  7. #7
    Registered User
    Join Date
    08-08-2014
    Location
    Dallas, TX
    MS-Off Ver
    2013
    Posts
    1

    Re: Delete only some of a cells contents

    I need a macro that will remove the dash from a cell. I have over 5000 id numbers in this format: 01-1001 I need to remove the "-" and keep the "0" (zero"). All these id number must only be 6 characters in length. Al 5000+ are in the same format. My macro does not record my steps.

    Example) cell contains: 01-1001

    I want to delete the dash leaving only 011001 This is in cell A2. Then i need the need the macro to move to the next row
    (A3) and repeat until my last row has the dash removed. I am very confused! Please help....

    Thanks.

  8. #8
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Delete only some of a cells contents

    In the future please comply with the Forum Rules when posting. See Forum Rule No. 2 - 2. Don't post a question in the thread of another member -- start your own. If you feel it's particularly relevant, provide a link to the other thread. You may include up to 3 links to other URLs in a single post, no more, so only link to the relevant pages.

    Maybe:

    Please Login or Register  to view this content.
    Last edited by JOHN H. DAVIS; 08-11-2014 at 06:20 AM.

+ 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. Delete Contents of Cells with 0
    By EJensen in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-04-2009, 05:10 PM
  2. Delete contents of cells
    By mikespeck in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 07-27-2006, 10:25 AM
  3. [SOLVED] Delete Contents of Cells
    By ir26121973 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 04-05-2006, 02:15 PM
  4. Replies: 3
    Last Post: 08-08-2005, 04:05 PM
  5. [SOLVED] Delete specific cells contents in a row with some locked cells in the same row
    By trussman in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-01-2005, 03:06 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