Dividing input by a constant
Hi,
Right click the sheet tab, View code and paste this in. Change the range to
suit
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count 1 Or IsEmpty(Target) Then Exit Sub
If Not Intersect(Target, Range("A1:A10")) Is Nothing Then' change to suit
If IsNumeric(Target) Then
On Error Resume Next
Application.EnableEvents = False
Target = Target / 5.7
Application.EnableEvents = True
On Error GoTo 0
End If
End If
End Sub
Mike
"BabyBlueAXiD" wrote:
Is there a way to create a formula or macro that when I enter a number in a
cell it will automatically divide 5.7?
|