asked on
Sub New_Delta()
Dim r As Long
' Go to last cell
r = Cells(Rows.Count, 2).End(xlUp).Offset(1, 0).Row
' Copy formula from cell above
Range(Cells(r - 1, "B"), Cells(r - 1, "R")).Copy
Range("B" & r).Insert shift:=xlDown
End Sub
Sub InsertCopyRow()
Dim Rng As Range
Set Rng = Range("B12").EntireColumn.Find("*", SearchOrder:=xlRows, SearchDirection:=xlPrevious)
If Not Rng Is Nothing Then Application.Goto Rng
Rng.Offset(1, 0).EntireRow.Insert
Rng.EntireRow.Copy Rng.Offset(1, 0).EntireRow
End Sub
ASKER
ASKER
Sub InsertCopyRow()
Dim Rng As Range
Set Rng = Range("B12").EntireColumn.Find("*", SearchOrder:=xlRows, SearchDirection:=xlPrevious)
If Not Rng Is Nothing Then Application.Goto Rng
Rng.Offset(1, 0).EntireRow.Insert
Rng.EntireRow.Copy Rng.Offset(1, 0).EntireRow
End Sub
ASKER
ASKER
Sub New_Delta()
Dim r As Long
' Go to last cell
r = Cells(Rows.Count, 2).End(xlUp).Offset(1, 0).Row
' Copy formula from cell above
Range(Cells(r - 1, "B"), Cells(r - 1, "R")).Copy
Range("B" & r).Insert shift:=xlDown
Application.CutCopyMode = False
End Sub
ASKER
ASKER
Microsoft Excel topics include formulas, formatting, VBA macros and user-defined functions, and everything else related to the spreadsheet user interface, including error messages.
TRUSTED BY
Open in new window
after:
Open in new window