+ Reply to Thread
Results 1 to 12 of 12

How to delete all cells in a single column if first 3 characters are ***

  1. #1
    Registered User
    Join Date
    09-26-2015
    Location
    london
    MS-Off Ver
    10
    Posts
    14

    How to delete all cells in a single column if first 3 characters are ***

    Hello I'm looking for an easy way how to delete all cells in a single column if those cells start with ***.
    The problem is that I can't just delete all rows with ***Record3 and ***Record5, because there are important data in other columns. So Record4 and Record6 must be moved one row up.

    Thank you for any help.

    Example:

    Column A:
    Record1
    Record2
    ***Record3
    Record4
    ***Record5
    Record6

    Output should be:

    Column A:
    Record1
    Record2
    Record4
    Record6

  2. #2
    Valued Forum Contributor mangesh.mehendale's Avatar
    Join Date
    06-04-2015
    Location
    India
    MS-Off Ver
    2007
    Posts
    510

    Re: How to delete all cells in a single column if first 3 characters are ***

    Hiii please let me know length of all records to be delete is = 10 and others = 7???
    Last edited by mangesh.mehendale; 09-28-2015 at 12:29 AM.
    Don`t care, take care...

    Regards,
    Mangesh

  3. #3
    Registered User
    Join Date
    09-26-2015
    Location
    london
    MS-Off Ver
    10
    Posts
    14

    Re: How to delete all cells in a single column if first 3 characters are ***

    Hello mangesh
    Record1 ... Record6 is just an example. "LEN" can be anywhere between 4 and 250.

  4. #4
    Valued Forum Contributor mangesh.mehendale's Avatar
    Join Date
    06-04-2015
    Location
    India
    MS-Off Ver
    2007
    Posts
    510

    Re: How to delete all cells in a single column if first 3 characters are ***

    Okay and there is "***" (asterisk marks) or these are characters like (ABC or 123)

  5. #5
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,532

    Re: How to delete all cells in a single column if first 3 characters are ***

    Is this how you wanted?
    Please Login or Register  to view this content.

  6. #6
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,526

    Re: How to delete all cells in a single column if first 3 characters are ***

    Hi bonpara,

    Try this (just initially on a copy of your data as the results cannot be undone if they're not as expected):

    Please Login or Register  to view this content.
    Regards,

    Robert
    ____________________________________________
    Please ensure you mark your thread as Solved once it is. Click here to see how
    If this post helps, please don't forget to say thanks by clicking the star icon in the bottom left-hand corner of my post

  7. #7
    Valued Forum Contributor mangesh.mehendale's Avatar
    Join Date
    06-04-2015
    Location
    India
    MS-Off Ver
    2007
    Posts
    510

    Re: How to delete all cells in a single column if first 3 characters are ***

    If you don`t want VBA Go with following steps

    Step 1: Press Ctrl+H

    Step 2: find- ~***(here * is treated as text) if these are asterisk marks of ABC* or 123* (here * represents series of character)..

    Step 3: press find ALL(below all result will be visible press Ctrl+A to select all found results

    Step 4: Press Ctrl + "-" and select Shift cells up and OK

  8. #8
    Registered User
    Join Date
    09-26-2015
    Location
    london
    MS-Off Ver
    10
    Posts
    14

    Re: How to delete all cells in a single column if first 3 characters are ***

    Hello Jindon.
    Thank you for your code. The problem with this code is that it will delete entire rows, so I would lose data in other columns. So I need to clear cells with a data starting with *** (three asterisks) and move data in column "A" up.

  9. #9
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,532

    Re: How to delete all cells in a single column if first 3 characters are ***

    Quote Originally Posted by bonpara View Post
    Hello Jindon.
    Thank you for your code. The problem with this code is that it will delete entire rows, so I would lose data in other columns. So I need to clear cells with a data starting with *** (three asterisks) and move data in column "A" up.
    OK then this should do
    Please Login or Register  to view this content.

  10. #10
    Registered User
    Join Date
    09-26-2015
    Location
    london
    MS-Off Ver
    10
    Posts
    14

    Re: How to delete all cells in a single column if first 3 characters are ***

    Hello Robert,
    Thank you very much for your code. As I mentioned earlier, the problem is that It will delete entire rows so I would lose data in a same row but in other columns.What I need is to clear cells with the asterisks at the beginning and then MOVE rest of the data up, so it won't delete entire row.
    But thank you anyway for trying.

    Bonpara

  11. #11
    Registered User
    Join Date
    09-26-2015
    Location
    london
    MS-Off Ver
    10
    Posts
    14

    Re: How to delete all cells in a single column if first 3 characters are ***

    This is It. It works perfet. Thank you Jindon, you really helped me a lot.
    Thank you very much.

    Quote Originally Posted by jindon View Post
    OK then this should do
    Please Login or Register  to view this content.

  12. #12
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,532

    Re: How to delete all cells in a single column if first 3 characters are ***

    You are welcome.

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

+ 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. [SOLVED] Delete rows where the column are given the less than X characters
    By nlyrk0 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-13-2015, 09:06 AM
  2. Delete everything but the first 4 characters in column A
    By MacroMania1 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 12-09-2011, 08:15 AM
  3. Delete all characters after the first two in multiple cells in a column
    By graham1298 in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 02-04-2011, 03:45 PM
  4. VBA Delete individual cells in a single column
    By ben_patto in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-21-2009, 09:50 PM
  5. Counting the Occurence of Special characters in Single/Multiple cells?
    By all4excel in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-23-2008, 03:33 PM
  6. Replies: 7
    Last Post: 12-14-2005, 11:10 PM
  7. Format single column cells to be 6 characters long
    By bubberz in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-12-2005, 02:58 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