Hi everyone. New to the forum and excel. I am having problems with runtime error '9' subscript out of range. The sheet is used to organize horse racing ratings for the day. I did not create this and it was working for the past week. Then I tried to run it this morning and kept coming up with the runtime error. Any help would be appreciated.
End If
End If
If Right(Sheets("Horse").Cells(A, B), 2) = "am" Then
Sheets("Horse").Cells(A, B) = Left(Cells(A, B), Len(Sheets("Horse").Cells(A, B)) - 2)
End If
If Right(Sheets("Horse").Cells(A, B), 3) = "am " Then
Sheets("Horse").Cells(A, B) = Left(Cells(A, B), Len(Sheets("Horse").Cells(A, B)) - 3)
End If
If Sheets("Horse").Cells(A, B) <> vbNullString Then
Races(C) = Sheets("Horse").Cells(A, 1) & Sheets("Horse").Cells(X - 1, B).Text
Time(C) = Sheets("Horse").Cells(A, B)
C = C + 1
End If
End If
If Right(Sheets("Horse").Cells(A, B), 2) = "am" Then
Sheets("Horse").Cells(A, B) = Left(Cells(A, B), Len(Sheets("Horse").Cells(A, B)) - 2)
End If
If Right(Sheets("Horse").Cells(A, B), 3) = "am " Then
Sheets("Horse").Cells(A, B) = Left(Cells(A, B), Len(Sheets("Horse").Cells(A, B)) - 3)
End If
If Sheets("Horse").Cells(A, B) <> vbNullString Then
Races(C) = Sheets("Horse").Cells(A, 1) & Sheets("Horse").Cells(X - 1, B).Text
Time(C) = Sheets("Horse").Cells(A, B)
C = C + 1