jackofalltrades2011
New Member
- Joined
- Jun 24, 2011
- Messages
- 4
Hello ALL!
my code is:
Sub ATA_total()
'
' Total column P of sheet(3) and paste total in Sheet(1)
'
Dim end_row_P As Long
end_row_P = Range("P1048576").End(xlUp).Row
Sheets(3).Range("P" & end_row_P + 2).Formula = "=SUM(P3:P" & end_row_P & ")"
Range("P" & end_row_P + 2).Select
Selection.Copy
Application.Goto Sheets(1).Range("B28")
Range("B28").Select.Paste
Selection.Paste
End Sub
I am trying to copy a cell value from one sheet to another sheet.
the goal is to get Application.Goto Sheets(1).Range("B28")= Range("P" & end_row_P + 2).Select
my code is:
Sub ATA_total()
'
' Total column P of sheet(3) and paste total in Sheet(1)
'
Dim end_row_P As Long
end_row_P = Range("P1048576").End(xlUp).Row
Sheets(3).Range("P" & end_row_P + 2).Formula = "=SUM(P3:P" & end_row_P & ")"
Range("P" & end_row_P + 2).Select
Selection.Copy
Application.Goto Sheets(1).Range("B28")
Range("B28").Select.Paste
Selection.Paste
End Sub
I am trying to copy a cell value from one sheet to another sheet.
the goal is to get Application.Goto Sheets(1).Range("B28")= Range("P" & end_row_P + 2).Select