Copy a column leaving out any blanks
Since you DID post in the Worksheet.Functions group
......Maybe you'd like a formula? :)
On Sheet1, cells A1:A20 contain a list of names and some blank cells
On Sheet2
Put this ARRAY FORMULA (committed with [Ctrl]+[Shift]+[Enter], instead of
just [Enter]in .....
A1:
=IF(COUNTA(Sheet1!$A$1:$A$20)=ROWS($1:1),INDEX(Sh eet1!$A$1:$A$20,SMALL(IF(Sheet1!$A$1:$A$20<"",ROW (Sheet1!$A$1:$A$20)),ROWS($1:1))),"")
Copy A1 and paste into A2 and down as far as you need.
Does that help?
***********
Regards,
Ron
XL2002, WinXP
"Ron Coderre" wrote:
How about using Autofilter to help?
Select the range of names, beginning with the
top name (or column label, if you have one)
From the Excel main menu:
<data<filter<autofilter
Click the dropdown arrow at the top of the list
Select..... "(nonblanks)".....(Now, only the non-blank cells are visible)
Select the list of visible names....The hidden blanks will not be copied
<edit<copy
Switch to the new location
Press [Enter] to paste
Does that help?
***********
Regards,
Ron
XL2002, WinXP
"Mike Pearson" wrote:
I have a column of names ie:
A
1 Bill
2 John
3
4 Mike
5 Rex
6 Stu
On another sheet, I want to have it list all the names on that list down a
column, but I want it to not carry over any blank cells. So on sheet2 it
would look like this:
A
1 Bill
2 John
3 Mike
4 Rex
5 Stu
Do you know how I can make that happen? Thank you in advance.
|