ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   extracting information from populated cells (https://www.excelbanter.com/excel-programming/277249-extracting-information-populated-cells.html)

Martyn

extracting information from populated cells
 
I have incoming emails which use an excel spreadsheet. I
need to set up a macro to extract all the populated cells
information and export to another excel file. I then use
information for printing labels so if there are loads of
blank entries then i have loads of wasted labels. The
problem is that cells (A:U/1:7) is taken by company logo.
Is there a way to extract just information from populated
cells from (A:U/7:??) Im new to vb so some code would be a
godsend!
Many thanks

Tom Ogilvy

extracting information from populated cells
 
Dim rng as Range
With Activesheet
set rng = .Range(.Range("A8"),.Cells(rows.count,1).End(xlup) ).Resize(,21)
End With
rng.copy Workbooks("Book2.xls").Worksheets(1).Range("A1")

if column A will have an entry in the last row.

--
Regards,
Tom Ogilvy

"martyn" wrote in message
...
I have incoming emails which use an excel spreadsheet. I
need to set up a macro to extract all the populated cells
information and export to another excel file. I then use
information for printing labels so if there are loads of
blank entries then i have loads of wasted labels. The
problem is that cells (A:U/1:7) is taken by company logo.
Is there a way to extract just information from populated
cells from (A:U/7:??) Im new to vb so some code would be a
godsend!
Many thanks





All times are GMT +1. The time now is 04:57 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com