Drrellik
Well-known Member
- Joined
- Apr 29, 2013
- Messages
- 844
- Office Version
- 365
- 2016
- 2013
- 2011
- 2010
- Platform
- Windows
<code class="vb plain">
I have searched and cant seem to find the right syntax for deleting down after a value is located in column B I managed to search the forum and get the preceding rows done. Any help would be appreciated.
Don</code>
Code:
' remove top rows down to row containing "Msn #"
Dim rng As Range
Dim X As Long
Const strstart As String = "Msn #"
X = Cells(Rows.Count, 1).End(xlUp).Row
Set rng = Cells(1, 1).Resize(X).Find(what:=strstart, LookIn:=xlValues, lookat:=xlWhole)
If Not rng Is Nothing Then
Cells(1, 1).Resize(rng.Row).EntireRow.delete
Set rng = Nothing
End If
' Remove rows below "Name" in column B
Insert your code here.... :)
I have searched and cant seem to find the right syntax for deleting down after a value is located in column B I managed to search the forum and get the preceding rows done. Any help would be appreciated.
Don</code>