Hello there, im using the following code so that I can enter time without colons
Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Target, Range("G:H")) Is Nothing Then
On Error GoTo FallThrough
Application.EnableEvents = False
Dim a As Range
For Each a In Intersect(Target, Range("G:H"))
If IsNumeric(a.Value) Then _
If a.Value > 1 And a.Value Mod 100 < 60 And Int(a.Value / 100) < 24 Then _
a = TimeValue(Int(a.Value / 100) & ":" & Format(a.Value Mod 100, "00"))
Next a
End If
FallThrough:
Application.EnableEvents = True
End Sub
The problem im having is that this code will only allow me to enter hh:mm. I need to enter hh:mm:ss. How would I modify or add to the code to be able to also enter the seconds in my time?
Im very new to this code thing so yeah im sure this will be a simple thing for some of you that have more advanced knowledge of excel.
Thanks in advance
Bookmarks