+ Reply to Thread
Results 1 to 7 of 7

Excel macro to delete blanks

  1. #1
    Registered User
    Join Date
    04-28-2013
    Location
    Bangalore
    MS-Off Ver
    Excel 2010
    Posts
    81

    Excel macro to delete blanks

    I have data like this

    Master item
    039 22 36 which is in bold and component item under the same
    039 15 12
    039 10 52
    039 10 45
    039 08 45

    i want it in the format mentioned below
    Master item Component item
    039 22 36 039 15 12
    039 22 36 039 10 52
    039 22 36 039 10 45
    039 22 36 039 08 45

    The number of components under each master item could vary and there are 2 lines of gap followed by next set of master and component items

    i want the data in the format mentioned above.

    Thanks in advance

  2. #2
    Registered User
    Join Date
    04-28-2013
    Location
    Bangalore
    MS-Off Ver
    Excel 2010
    Posts
    81

    Re: Excel macro to delete blanks

    The master item is always in Bold followed by component items under it(the number could vary).. followed by 2 lines of space and next of master item and component items

  3. #3
    Forum Contributor Bhuvi's Avatar
    Join Date
    04-19-2013
    Location
    Delhi, India
    MS-Off Ver
    MS Excel 2003,07,10
    Posts
    153

    Re: Excel macro to delete blanks

    Hi,

    for a manual approach you can use the formula
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    where A1 is the master field and A2,A3... are components, just drag the formula,
    You can change A1 when the master changes
    If this helped and you wish to say thanks, then Please click on the Star* icon below this post.

  4. #4
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Excel macro to delete blanks

    Please Login or Register  to view this content.
    Assuming that "039 22 36" is in column A and not spread across three columns.

  5. #5
    Registered User
    Join Date
    04-28-2013
    Location
    Bangalore
    MS-Off Ver
    Excel 2010
    Posts
    81

    Re: Excel macro to delete blanks

    Hi, 039 22 36 are in 3 different columns

  6. #6
    Registered User
    Join Date
    04-28-2013
    Location
    Bangalore
    MS-Off Ver
    Excel 2010
    Posts
    81

    Re: Excel macro to delete blanks

    The department class n item needs to be concatenated as hey are in 3 different columns..the desired output can be displayed from column n

  7. #7
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Excel macro to delete blanks

    Please Login or Register  to view this content.

+ 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] Insert and Delete blanks rows so that there are 2 blanks rows between text rows
    By erniedawg in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 06-29-2013, 02:27 AM
  2. [SOLVED] Help with a macro to delete empty (but not blank) cells OR sort blanks to the bottom
    By Cyali in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-07-2012, 09:04 PM
  3. Delete Blanks
    By ibaker in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-31-2010, 02:29 AM
  4. where's the delete blanks command
    By luv2glyd in forum Excel General
    Replies: 5
    Last Post: 07-18-2010, 11:20 AM
  5. Replies: 7
    Last Post: 02-09-2005, 02:09 AM

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