+ Reply to Thread
Results 1 to 6 of 6

Insert blank cell before bold names

  1. #1
    Registered User
    Join Date
    02-05-2007
    Posts
    11

    Insert blank cell before bold names

    I have 5000 names and addresses that are in excel as one long column, each cell has data., there is no space between address blocks. I need to divide the addresses, and they are not all the same number of cells. The only distinquishing field is the name, which bold. Is there a what to format this, inserting a blank cell before each cell that is formatted with bold?

  2. #2
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Insert blank cell before bold names

    Copy this code to a standard module and give it a try. Assumption: "bold" cells are in column-A. Change reference in code as required.

    Please Login or Register  to view this content.
    Palmetto

    Do you know . . . ?

    You can leave feedback and add to the reputation of all who contributed a helpful response to your solution by clicking the star icon located at the left in one of their post in this thread.

  3. #3
    Registered User
    Join Date
    02-05-2007
    Posts
    11

    Re: Insert blank cell before bold names

    Thank you, but I don't have a clue where to put that code? Module, is that a formula? DO I select the whole column first?

    Sorry, but I am a newbie.

  4. #4
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Insert blank cell before bold names

    Open the target workbook, then

    Adding the Macro

    1. Highlight and copy the macro above pressing the keys CTRL+C
    2. Press the keys ALT+F11 to open the Visual Basic Editor
    3. Press the keys ALT+I to activate the Insert menu
    4. Press M to insert a Standard Module
    5. Paste the code by pressing the keys CTRL+V
    6. Make any custom changes to the macro if needed at this time.
    7. Save the Macro by pressing the keys CTRL+S
    8. Press the keys ALT+Q to exit the Editor, and return to Excel.


    To Run the Macro...
    To run the macro from Excel, open the workbook, and press ALT+F8 to display the Run Macro Dialog. Double Click the macro's name to Run it.

  5. #5
    Registered User
    Join Date
    11-12-2013
    Location
    New York
    MS-Off Ver
    Excel 2003
    Posts
    1

    Re: Insert blank cell before bold names

    Quote Originally Posted by Palmetto View Post
    Open the target workbook, then

    Adding the Macro

    1. Highlight and copy the macro above pressing the keys CTRL+C
    2. Press the keys ALT+F11 to open the Visual Basic Editor
    3. Press the keys ALT+I to activate the Insert menu
    4. Press M to insert a Standard Module
    5. Paste the code by pressing the keys CTRL+V
    6. Make any custom changes to the macro if needed at this time.
    7. Save the Macro by pressing the keys CTRL+S
    8. Press the keys ALT+Q to exit the Editor, and return to Excel.


    To Run the Macro...
    To run the macro from Excel, open the workbook, and press ALT+F8 to display the Run Macro Dialog. Double Click the macro's name to Run it.

    This works great but how do I insert the row above the BOLD rather than below?

    Thanks!

  6. #6
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Insert blank cell before bold names

    Change this line from
    Please Login or Register  to view this content.
    to
    Please Login or Register  to view this content.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

+ 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