Link to home
Start Free TrialLog in
Avatar of Ted Penner
Ted PennerFlag for United States of America

asked on

Macro to save highlighted rows as a separate file

I need to be able to select multiple rows from any spreadsheet, and save them as a separate workbook.
ASKER CERTIFIED SOLUTION
Avatar of Rgonzo1971
Rgonzo1971

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Sub CreateWB()

Dim wbNew As Workbook

With Selection
    Set wbNew = Workbooks.Add(1)
    wbNew.Sheets(1).Paste
End With


End Sub

Open in new window

Avatar of Ted Penner

ASKER

Martin, yours looked the cleanest but produced the code itself in a different workbook.
perfection!