program carriage return
Try this event sub:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 4 Then
Range("C" & Target.Row + 1).Select
Else
If Target.Column = 3 Then
Range("D" & Target.Row).Select
End If
End If
End Sub
To install it:
Right click on worksheet in VBA Project explorer window, choose View code
and copy sub into the worksheet code window!
Regards,
Stefi
€˛MarkM€¯ ezt Ć*rta:
I have a situation wherein I have 2 columns of identifiers in columns A & B.
I'm scanning bar codes into columns C & D. What I would like to have happen
is that after I scan into column D for focus to go to the next row, column C.
But when I leave column C, I want to go to column D (which it currently
does).
Right now, I have to press the Enter key after scanning into columns C & D,
but I have hundreds of rows that I'm scanning, and it would be a lot easier
(and efficient) to not have to continually go back to the keyboard and just
use the scan gun. I looked at trying to program the scan gun, but could not
figure out a way to get the desired functionality.
I am not familiar with macro programming, so that may be my ultimate
solution, but I was hoping for a simple formula that I could use to help me
out here.
Thanks,
Mark
|