Locat a cell
Awesome!!!
"JW" wrote:
Sub foofer()
Dim r As Long
r = Cells.Find(What:="Grand Total", After:=ActiveCell,
LookIn:=xlFormulas, _
LookAt:=xlWhole, SearchOrder:=xlByRows,
SearchDirection:=xlNext, _
MatchCase:=False, SearchFormat:=False).Row
Range(Cells(r + 1, 1), Cells(65536, 1)).EntireRow.Delete
End Sub
pgarcia wrote:
Hello agina. Thanks for the below code.
I'm using this code again but for something elso. Whith the below code, how
can I selecet the next row and delete all infomaton from that row on down?
Thanks
"JW" wrote:
Is "Grand Total" only found one time in your whole worksheet? If so:
Sub foofer()
Dim r As Long
r = Cells.Find(What:="Grand Total", After:=ActiveCell,
LookIn:=xlFormulas, _
LookAt:=xlWhole, SearchOrder:=xlByRows,
SearchDirection:=xlNext, _
MatchCase:=False, SearchFormat:=False).Row
With Range("A" & r & ":W" & r).Font
.Bold = True
.Size = 12
.ColorIndex = 5
End With
End Sub
The above sub will do what you want without physically going to the
row containing Grand Total. If you want it to do that, you could just
change the .Row to a .Activate and establish the row then.
HTH
-Jeff-
pgarcia wrote:
I have a cell in D2945 (changes daily). In that cell it reads "Grand Total".
I would like to be able to go to that cell, then go to the begining of that
row, selece row A-W, bold, change color to blue and font 12 points. Does
anyone know how to do this?
Thanks
|