Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Worksheet Functions / March 2008

Tip: Looking for answers? Try searching our database.

How to auto tab

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Joel Ganger - 24 Mar 2008 22:20 GMT
I use a handheld scanner to read barcodes. How do I make excel automatically
tab to the next cell after input.
L. Howard Kittle - 25 Mar 2008 00:53 GMT
Hi Joel,

Did a project using a scanner and I used an event macro,  Worksheet Change
to make stuff happen when an item was entered with the scanner.

HTH
Regards,
Howard

>I use a handheld scanner to read barcodes. How do I make excel
>automatically
> tab to the next cell after input.
Joel Ganger - 25 Mar 2008 13:02 GMT
Ok sounds simply enough, how do I do it?

> Hi Joel,
>
[quoted text clipped - 8 lines]
> >automatically
> > tab to the next cell after input.
L. Howard Kittle - 25 Mar 2008 19:28 GMT
Hi Joel,

Use something like this.  If something is scanned into column  A, then this
macro will fire and you will get the message.  Or you can call a macro to do
what you want with the scanned entry which is what I did by calling
StudentID, (which I have edited out here).

So in my example once a student ID number is scanned into column 1  the
macro StudentID is called and the date and time and student information is
entered in that row.  The StudentID macro draws it's info from a data base
on sheet 2 and commits it to sheet 1.

I am not an expert but if you need help getting it set up you could send me
a sample workbook and I will give it a go.  Provide plenty of details of
what you want to happen and where, etc. xxxlhkittle@comcast.net dump the xxx

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 1 Then
Application.EnableEvents = False
'StudentID
MsgBox "I just scanned something"
Application.EnableEvents = True
End If
End Sub

Sub StudentID()
Dim FindVal As Variant
Dim fVal As Range

FindVal = Worksheets("Sheet1").Range("A65536").End(xlUp).Value
Set fVal = Worksheets("Sheet2").Columns("A").Find(FindVal)

If Not fVal Is Nothing Then
   fVal.Offset(0, 1).Resize(1, 5).Copy _
   Sheets("Sheet1").Range("D25000").End(xlUp).Offset(1, 0)
   ActiveCell.Offset(-1, 1) = Date
   ActiveCell.Offset(-1, 2) = Time
End If
If ActiveCell.Offset(-1, 4).Value = "" Then
   ActiveCell.Offset(-1, 3).Value = " No student data for this ID no."
   ActiveCell.Offset(-1, 1) = ""
   ActiveCell.Offset(-1, 2) = ""
End If
End Sub

HTH
Regards,
Howard

>I use a handheld scanner to read barcodes. How do I make excel
>automatically
> tab to the next cell after input.
L. Howard Kittle - 26 Mar 2008 02:39 GMT
Hi Joel,

Too much information in my reply, try one of these...
First Tabs rows and second Tabs Colums.

Option Explicit

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 1 Then
ActiveCell.Offset(1, 0).Select
End If
End Sub

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 1 Then
ActiveCell.Offset(0, 1).Select
End If
End Sub

HTH
Regards
Howard

>I use a handheld scanner to read barcodes. How do I make excel
>automatically
> tab to the next cell after input.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.