A
Anthony Warburton
I have a macro with the following script:-
Option Explicit
Sub Deposit()
Dim fromWks As Worksheet
Dim toWks As Worksheet
Dim toCell As Range
Set fromWks = ActiveSheet
Set toWks = Worksheets("Deposits")
With toWks
Set toCell = .Cells(.Rows.Count, "C").End
(xlUp).Offset(2, 0)
End With
With fromWks
toCell.Value = .Range("H3").Value
toCell.Offset(0, 2).Value = .Range("D12").Value
toCell.Offset(0, 4).Value = .Range("D14").Value
End With
End Sub
The above will paste certain selected cells into
my 'deposits' worksheet which is great, but is there a way
to actually get it to select a range of cells paste them
into 'deposits' worksheet then select another set of cells
and past them on the next line in the 'deposits' worksheet
in ONE CLICK ??
Option Explicit
Sub Deposit()
Dim fromWks As Worksheet
Dim toWks As Worksheet
Dim toCell As Range
Set fromWks = ActiveSheet
Set toWks = Worksheets("Deposits")
With toWks
Set toCell = .Cells(.Rows.Count, "C").End
(xlUp).Offset(2, 0)
End With
With fromWks
toCell.Value = .Range("H3").Value
toCell.Offset(0, 2).Value = .Range("D12").Value
toCell.Offset(0, 4).Value = .Range("D14").Value
End With
End Sub
The above will paste certain selected cells into
my 'deposits' worksheet which is great, but is there a way
to actually get it to select a range of cells paste them
into 'deposits' worksheet then select another set of cells
and past them on the next line in the 'deposits' worksheet
in ONE CLICK ??