Hi all,
Not that great on Excel so looking for some help please. I have the below VBA that will transfer data from certain cells on Worksheet 1 to different cells on Worksheet 2. It is copying the formulas in these cells where I need it to copy just the values.
Sub DataTransfer()
Dim ws1 As Worksheet, ws2 As Worksheet
Dim DestRow As Long
Set ws1 = Sheets("Data Entry")
Set ws2 = Sheets("Results")
DestRow = ws2.Cells(Rows.Count, "C").End(xlUp).Row + 1
ws1.Range("K22").Copy ws2.Range("C" & DestRow)
ws1.Range("K23").Copy ws2.Range("D" & DestRow)
ws1.Range("K24").Copy ws2.Range("E" & DestRow)
ws1.Range("F30").Copy ws2.Range("F" & DestRow)
ws1.Range("F26").Copy ws2.Range("H" & DestRow)
ws1.Range("K28").Copy ws2.Range("I" & DestRow)
ws1.Range("K27").Copy ws2.Range("J" & DestRow)
ws1.Range("F24").Copy ws2.Range("K" & DestRow)
ws1.Range("G36").Copy ws2.Range("L" & DestRow)
ws1.Range("G35").Copy ws2.Range("M" & DestRow)
End Sub
Hoping I have worded it OK above and any help would be much appreciated.
Thanks
Not that great on Excel so looking for some help please. I have the below VBA that will transfer data from certain cells on Worksheet 1 to different cells on Worksheet 2. It is copying the formulas in these cells where I need it to copy just the values.
Sub DataTransfer()
Dim ws1 As Worksheet, ws2 As Worksheet
Dim DestRow As Long
Set ws1 = Sheets("Data Entry")
Set ws2 = Sheets("Results")
DestRow = ws2.Cells(Rows.Count, "C").End(xlUp).Row + 1
ws1.Range("K22").Copy ws2.Range("C" & DestRow)
ws1.Range("K23").Copy ws2.Range("D" & DestRow)
ws1.Range("K24").Copy ws2.Range("E" & DestRow)
ws1.Range("F30").Copy ws2.Range("F" & DestRow)
ws1.Range("F26").Copy ws2.Range("H" & DestRow)
ws1.Range("K28").Copy ws2.Range("I" & DestRow)
ws1.Range("K27").Copy ws2.Range("J" & DestRow)
ws1.Range("F24").Copy ws2.Range("K" & DestRow)
ws1.Range("G36").Copy ws2.Range("L" & DestRow)
ws1.Range("G35").Copy ws2.Range("M" & DestRow)
End Sub
Hoping I have worded it OK above and any help would be much appreciated.
Thanks