Hello,

I have a code below and wonder if you can modify this into private sub. Thanks

Sub macro2()


If ActiveSheet.Range("Y4") > 10 / 100 Then
    ActiveSheet.Shapes.Range(Array("Freeform 42")).Fill.ForeColor.RGB = vbGreen
    ElseIf ActiveSheet.Range("Y4") < 9.99 / 100 And ActiveSheet.Range("Y4") > 5.99 / 100 Then
    ActiveSheet.Shapes.Range(Array("Freeform 42")).Fill.ForeColor.RGB = vbYellow
    ElseIf ActiveSheet.Range("Y4") < 5.99 / 100 Then
    ActiveSheet.Shapes.Range(Array("Freeform 42")).Fill.ForeColor.RGB = vbRed

End If
End Sub