LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 41
Default Deleting rows when cell text reads "Research"

I have a spreadsheet with 8,000 rows that I have performed some work on. In
column W "Research" and numbers appear. I have written in my macro so that
the data is sorted so that all the Research appears in the first rows.

How do I delete rows, as quickly as possible, that have Research in Column W?

I wrote the following Loop but it doesn't work and I am not sure that a Loop
is the quickest way to accomplish this. Column V is blank. I was trying to
establish a block of rows to be deleted and delete all at once.

Sub Macro1()
Range("V7").Select
ActiveCell.Formula = "1"
Range("W7").Select
X = ActiveCell.Row

Do While Cells(X, 23).Text = "Research"
X = X + 1
Loop

ActiveCell.Select
ActiveCell.Offset(-1, -1).Select
Selection.End(xlUp).Select
Selection.EntireRow.Delete Shift:=xlUp


End Sub

 
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
Format a cell such that "#NAME?" reads/appears "N/A"? Fred Holmes Excel Discussion (Misc queries) 3 June 18th 09 06:32 AM
Cell reads "Value" without an entry Mark Excel Worksheet Functions 6 February 6th 09 05:53 AM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
When I input "25:03" as a time, it reads "1:03" Darryl_Neeley Excel Discussion (Misc queries) 9 September 26th 07 09:20 PM
Is there a formula thet reads (If A2=A1,"",INSERT PAGE BREAK) ? Gentleman Excel Discussion (Misc queries) 3 October 9th 06 05:25 PM


All times are GMT +1. The time now is 04:47 AM.

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

About Us

"It's about Microsoft Excel"