Macro to copy a range
Thank you for the code.
It did the trick and did copy the data to the second sheet....BUT
I also received an error message
"Run time error 1004"
"Copy method of range class failed"
I wonder why the error
"J.E. McGimpsey" wrote in message
...
One way:
Public Sub CopyVisible()
Sheets("db1").Range("A1").CurrentRegion.SpecialCel ls( _
xlCellTypeVisible).Copy Destination:=Sheets(2).Range("A1")
End Sub
In article
.rogers.com,
"PCOR" wrote:
I have asked in other NG. Got some very good answers from very helpful
people (The trouble was that these people assumed that I know a great
deal
about EXcel...I do not)that left me a little confused. Here is my
predicament
I have a sheet called db1
The sheet contains data in Col A, B ,C, D,E,F,G,H,I,J
I have applied a filter to this sheet. Col A is set to show only NON
BLANK
lines
I want to copy the data currently displayed(Ie NON blank lines) to and
other
sheet
The columns are always the same ones but the number of rows varies all
the
time.
So I need a macro that will copy from ALL and only the visible data.
(ie copy the data in the above named columns down to the last row
showing .
Can/will some one give me the code required to do this.
Thanks and Have a very happy 2004
|