Posted to microsoft.public.excel.programming
|
|
Find current row number and select row
This worked for me.
Thanks!
--
JohnM
"p45cal" wrote:
You may not need to do any sorting, try this on an experimental
worksheet:
Sub DeleteBlankNARecords()
Dim RowNum As Integer
Sheets("PlDetails").Select
For RowNum = 896 To 2 Step -1
If Application.WorksheetFunction.IsNA(Cells(RowNum, "D")) Then
Rows(RowNum).Delete
'perhaps change the line above to whatever is in column D that you
want to delete eg.:
'If Cells(RowNum, "D").Value = "N/A" Or Cells(RowNum, "D").Value = ""
Then Rows(RowNum).Delete
'you get the drift
Next RowNum
End Sub
--
p45cal
*p45cal*
------------------------------------------------------------------------
p45cal's Profile: http://www.thecodecage.com/forumz/member.php?userid=558
View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=125286
|