![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Board Regular
Join Date: Feb 2002
Location: Jefferson City, Missouri
Posts: 383
|
What would be the proper way to write code to check for all blank cells in Range(A9:A130) and then delete those rows that are blank?
I've tried using: if(isblank(Range(A9:a130)) then cells.entirerow.delete but it wouldn't work. thanks, _________________ Soon I hope to be answering alot of these questions instead of asking them. viper [ This Message was edited by: viper on 2002-05-18 10:20 ] |
|
|
|
|
|
#2 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Sydney, Australia
Posts: 2,908
|
Hello Viper,
This single line of code should do what you want:- Range("A9:A130").SpecialCells(xlCellTypeBlanks).EntireRow.Delete HTH, Dan |
|
|
|
|
|
#3 |
|
MrExcel MVP
Join Date: Apr 2002
Location: Vancouver BC , Canada
Posts: 6,259
|
WOW !!!!
|
|
|
|
|
|
#4 |
|
Board Regular
Join Date: Feb 2002
Location: Jefferson City, Missouri
Posts: 383
|
Excellent dk.
Thank you so much. Worked perfectly.
__________________
I appreciate the help from everyone at Mr. Excel. viper |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|