If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
deleting blank rorws
I imported some information from a web page and when it loaded it has huge
amounts of blank rows, how can I delete these without doing each small bunch of rows individually. Ex: I have the company name and then 12 rows later I get the phone number then five rows later there is the address. I might add that it is not uniform in any way now of the blanks row amounts are the same. All total there should be 101 company entries that should take up about 404 rows, but instead it takes up 19822. Oh and all this information is only in column A (which is OK but most of your help answers say I need more than one column of data). Please help, I know there has to be an easier way. I hope that you understand this as it is hard to explain. -- VRaybandb |
#2
|
|||
|
|||
deleting blank rorws
Try this small macro:
Sub rowkiller() n = Cells(Rows.Count, "A").End(xlUp).Row For i = n To 1 Step -1 If Cells(i, 1).Value = "" Then Cells(i, 1).EntireRow.Delete End If Next End Sub -- Gary''s Student - gsnu200819 "VRaybandb" wrote: I imported some information from a web page and when it loaded it has huge amounts of blank rows, how can I delete these without doing each small bunch of rows individually. Ex: I have the company name and then 12 rows later I get the phone number then five rows later there is the address. I might add that it is not uniform in any way now of the blanks row amounts are the same. All total there should be 101 company entries that should take up about 404 rows, but instead it takes up 19822. Oh and all this information is only in column A (which is OK but most of your help answers say I need more than one column of data). Please help, I know there has to be an easier way. I hope that you understand this as it is hard to explain. -- VRaybandb |
#3
|
|||
|
|||
deleting blank rorws
OK Gary I am stupid, I am not sure where I am suppose to insert the macro?
Can you give me the "how to delete rows for dummies"? Thanks -- VRaybandb "Gary''s Student" wrote: Try this small macro: Sub rowkiller() n = Cells(Rows.Count, "A").End(xlUp).Row For i = n To 1 Step -1 If Cells(i, 1).Value = "" Then Cells(i, 1).EntireRow.Delete End If Next End Sub -- Gary''s Student - gsnu200819 "VRaybandb" wrote: I imported some information from a web page and when it loaded it has huge amounts of blank rows, how can I delete these without doing each small bunch of rows individually. Ex: I have the company name and then 12 rows later I get the phone number then five rows later there is the address. I might add that it is not uniform in any way now of the blanks row amounts are the same. All total there should be 101 company entries that should take up about 404 rows, but instead it takes up 19822. Oh and all this information is only in column A (which is OK but most of your help answers say I need more than one column of data). Please help, I know there has to be an easier way. I hope that you understand this as it is hard to explain. -- VRaybandb |
#4
|
|||
|
|||
deleting blank rorws
an option may be to use filters, then set the filter to blank rows and delete
them all that way. Select all the data by clicking on the block above 1 and to the left of A. Then select data/Filter, then click on the pull-down and select "blank rows". You can then just delet ALL the rows that are left, and these will be the blank rows you want to get rid of "VRaybandb" wrote: I imported some information from a web page and when it loaded it has huge amounts of blank rows, how can I delete these without doing each small bunch of rows individually. Ex: I have the company name and then 12 rows later I get the phone number then five rows later there is the address. I might add that it is not uniform in any way now of the blanks row amounts are the same. All total there should be 101 company entries that should take up about 404 rows, but instead it takes up 19822. Oh and all this information is only in column A (which is OK but most of your help answers say I need more than one column of data). Please help, I know there has to be an easier way. I hope that you understand this as it is hard to explain. -- VRaybandb |
#5
|
|||
|
|||
deleting blank rorws
Select column A then F5SpecialBlanks.
EditDeleteEntire Row. Gord Dibben MS Excel MVP On Tue, 9 Dec 2008 11:25:01 -0800, VRaybandb wrote: I imported some information from a web page and when it loaded it has huge amounts of blank rows, how can I delete these without doing each small bunch of rows individually. Ex: I have the company name and then 12 rows later I get the phone number then five rows later there is the address. I might add that it is not uniform in any way now of the blanks row amounts are the same. All total there should be 101 company entries that should take up about 404 rows, but instead it takes up 19822. Oh and all this information is only in column A (which is OK but most of your help answers say I need more than one column of data). Please help, I know there has to be an easier way. I hope that you understand this as it is hard to explain. |
#6
|
|||
|
|||
deleting blank rorws
Thank you so much, that was so easy and I just knew that there had to be an
EASY way and this was way too easy. Thank you soooooo much, -- VRaybandb "Gord Dibben" wrote: Select column A then F5SpecialBlanks. EditDeleteEntire Row. Gord Dibben MS Excel MVP On Tue, 9 Dec 2008 11:25:01 -0800, VRaybandb wrote: I imported some information from a web page and when it loaded it has huge amounts of blank rows, how can I delete these without doing each small bunch of rows individually. Ex: I have the company name and then 12 rows later I get the phone number then five rows later there is the address. I might add that it is not uniform in any way now of the blanks row amounts are the same. All total there should be 101 company entries that should take up about 404 rows, but instead it takes up 19822. Oh and all this information is only in column A (which is OK but most of your help answers say I need more than one column of data). Please help, I know there has to be an easier way. I hope that you understand this as it is hard to explain. |
#7
|
|||
|
|||
deleting blank rorws
Good to hear.
Thanks for the feedback. Gord On Wed, 10 Dec 2008 07:21:01 -0800, VRaybandb wrote: Thank you so much, that was so easy and I just knew that there had to be an EASY way and this was way too easy. Thank you soooooo much, |
Thread Tools | |
Display Modes | |
|
|