Results 1 to 4 of 4

Macro that searches a column for all the blank cells then highlights the row entire row.

Threaded View

  1. #1
    Registered User
    Join Date
    10-08-2012
    Location
    Scotland
    MS-Off Ver
    Excel 2010
    Posts
    8

    Macro that searches a column for all the blank cells then highlights the row entire row.

    Hi all,

    As stated above I am attempting to create a macro that will search a specific column for all the blank cells and highlight/selct the entire row, then copy the highlighted/slected rows to a new spread sheet.

    So far I can search and highlight all blank cells within a range however when I add to the macro to allow it to highlight the entire row it only selects the first blank cell rather than all of them.

    Any and all inputs would be greatly appreciated and any suggestion to improve the macro further would also be welcome.

    Thanks,


    Sub mySub()
    Dim Rng As Range
    
    ActiveSheet.Range("A1:A10").SpecialCells _
            (xlCellTypeBlanks).Select
    ActiveCell.EntireRow.Select
    
        
        
        Set Rng = Selection
        Selection.Copy
       
        Sheets("Sheet2").Range(Rng.Address).PasteSpecial (xlPasteAll)
        
    
    End Sub
    Last edited by arlu1201; 10-09-2012 at 09:07 AM. Reason: Use code tags in future.

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