Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 208
Default Deleting rows based upon the value in column D

Hi, I would like to delete all rows in my spreadheet that have a non-numeric
or null value in column D.

The length of my spreadsheet will vary in length and there is no column
headings in the spreadsheet, just pure data from row A onwards.

Thanks in advance.
Sean

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Deleting rows based upon the value in column D

On Error Resume Next
columns(4).SpecialCells(xlConstants,xlTextValues). EntireRow.Delete
columns(4).SpecialCells(xlBlanks).EntireRow.Delete
On Error goto 0

If the values are produced by formulas you can use xlFormulas,xlTextValues

if you have error values
xlFormulas,xlErrors

or Logical

xlFormulas,xlLogical

See help on special cells for other options.

--
Regards,
Tom Ogilvy


"Sean" wrote in message
...
Hi, I would like to delete all rows in my spreadheet that have a

non-numeric
or null value in column D.

The length of my spreadsheet will vary in length and there is no column
headings in the spreadsheet, just pure data from row A onwards.

Thanks in advance.
Sean



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Deleting rows based upon the value in column D


very nice, I was able to consolidate the following three lines
recorded, into one.

Columns("B:B").Select
Selection.SpecialCells(xlCellTypeBlanks).Select
Selection.EntireRow.Delete

Thanks, To

--
ackur
-----------------------------------------------------------------------
ackurv's Profile: http://www.excelforum.com/member.php...fo&userid=1552
View this thread: http://www.excelforum.com/showthread.php?threadid=27204

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Deleting Rows based on a Value Max2073 Excel Worksheet Functions 2 August 14th 09 01:34 PM
Deleting rows based on column values Dazed and Confused[_2_] New Users to Excel 3 February 6th 09 10:47 PM
Deleting Rows based on Column Critieria blackmanofsteel40 Excel Discussion (Misc queries) 1 September 7th 07 09:05 PM
Deleting Rows based on text in cell & formatting cell based on text in column beside it Steve Excel Programming 4 February 26th 04 03:31 PM
Deleting rows based on criteria John Walker[_2_] Excel Programming 2 December 12th 03 08:37 PM


All times are GMT +1. The time now is 09:35 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"