Good Afternoon,
I hope someone will be able to help me with following situation
Im working on a file with a lot of data. The macro used was working perfectly until recently. Im not the one who created it and I don"t have many knowledge on Macros...
The goal is to have the price in column S divided per 100 and to have the unit per 1 (instead of 100) in column U. (ref. screenshot)> This is the macro :
Sub FindandReplace()
'Price per unit
last_row = Sheets("SAPSource").Cells(63500, 15).End(xlUp).Row
Range("U2:U" & last_row).Select
Selection.Copy
Range("S2:S" & last_row).Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlDivide, _
SkipBlanks:=False, Transpose:=False
Sheets("SAPSource").Cells(2, 21).Value = 1
Sheets("SAPSource").Cells(2, 21).Select
Selection.Copy
Range("U2:U" & last_row).Select
Selection.PasteSpecial Paste:=xlPasteValues, SkipBlanks:=False, Transpose:=False
Do you have an idea of what's the problem here?
Thank you so much for your help
I hope someone will be able to help me with following situation
Im working on a file with a lot of data. The macro used was working perfectly until recently. Im not the one who created it and I don"t have many knowledge on Macros...
The goal is to have the price in column S divided per 100 and to have the unit per 1 (instead of 100) in column U. (ref. screenshot)> This is the macro :
Sub FindandReplace()
'Price per unit
last_row = Sheets("SAPSource").Cells(63500, 15).End(xlUp).Row
Range("U2:U" & last_row).Select
Selection.Copy
Range("S2:S" & last_row).Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlDivide, _
SkipBlanks:=False, Transpose:=False
Sheets("SAPSource").Cells(2, 21).Value = 1
Sheets("SAPSource").Cells(2, 21).Select
Selection.Copy
Range("U2:U" & last_row).Select
Selection.PasteSpecial Paste:=xlPasteValues, SkipBlanks:=False, Transpose:=False
Do you have an idea of what's the problem here?
Thank you so much for your help