I've had a macro running for over 3 years, but now it has suddenly started returning the incorrect column Number, even when the cursor is firmly in Column 1.
It keeps selecting column Y. EVERY TIME !
It doesn't matter what I select as the ActiveCell.
Any ideas what could be causing this ?
If a virus is a possibility, any suggestions as to where I should start looking.
Here's the code bit that I'm using which is causing the problem.
I added the MsgBox ActiveCell.Column at the end so that I could see what column it was selecting.
Sub GetCell()
Dim myRow As Long
Dim val As String
val = ActiveCell.Value
myRow = ActiveCell.Row
If ActiveCell.Column <> 1 Then
MsgBox ActiveCell.Column
MsgBox " Select a Lot Number "
Exit Sub
End If
MsgBox ActiveCell.Column
End Sub