I have a code which works fine . It takes changing values from cell "AB10" together with the small value of .0001 and lists them in column "AJ"
The additional small value is required for conditional formatting elsewhere but does not effect the final result which is in a cell that is formatted to ignore decimal places.
The code I use is
Sub_Tally_Values
Range("AB10"). CopyRange("AB10").Value=Range("AB10")+0.0001
Range("AJ" & Rows.Count). End (xlUp). Offset(1,0).PasteSpecial xlPasteValues
End Sub
My problem comes when I try to add an if statement as a condition of it to run. The code I want to place in front of it would only let it run if "AB6" or AB13 is less than 0.0003
I tried If Range("AB6").Value < 0.0003 Or Range("AB13").Value < 0.0003 Then - - - I do not know where to place the End if What ever I try does not work.
Any help with this would be appreciated
The additional small value is required for conditional formatting elsewhere but does not effect the final result which is in a cell that is formatted to ignore decimal places.
The code I use is
Sub_Tally_Values
Range("AB10"). CopyRange("AB10").Value=Range("AB10")+0.0001
Range("AJ" & Rows.Count). End (xlUp). Offset(1,0).PasteSpecial xlPasteValues
End Sub
My problem comes when I try to add an if statement as a condition of it to run. The code I want to place in front of it would only let it run if "AB6" or AB13 is less than 0.0003
I tried If Range("AB6").Value < 0.0003 Or Range("AB13").Value < 0.0003 Then - - - I do not know where to place the End if What ever I try does not work.
Any help with this would be appreciated