Record entry and exit times with Barcodes in Excel

Поделиться
HTML-код
  • Опубликовано: 12 сен 2024
  • Record entry and exit times with Barcodes in Excel. With a barcode scanner record the in and out times on an Excel spread sheet.Check out my templates page for free and purchased templates www.easyexcela...
    Check out my online training www.easyexcelanswers.com/courses.html
    For more help visit my website www.easyexcelan... or email me at easyexcelanswers@gmail.com.
    Contact me regarding customizing this template for your needs.
    Click for online Excel Consulting www.calendly.co...
    Excel one-on-one on-line training available. Email me to arrange.
    I am able to provide online help on your computer at a reasonable rate.
    www.amazon.com...
    Check out my next one-hour Excel Webinar
    www.crowdcast....
    I use a Blue condensor Microphone to record my videos, here is the link
    amzn.to/37gyyGa
    Check out Crowdcast for creating your webinars
    app.linkmink.c...
    If you need to buy Office 2019 follow
    amzn.to/2VX5dv8
    I use Tube Buddy to help promote my videos
    Check them out
    www.Tubebuddy....
    Follow me on Facebook
    / easyexcel.answers
    TWEET THIS VIDEO • Record entry and exit ...
    Follow me on twitter
    easyexcelanswers
    IG @barbhendersonconsulting
    You can help and generate a translation to you own language
    www.youtube.com...
    *this description may contain affiliate links. When you click them, I may receive a small commission at no extra cost to you. I only recommend products and services that I've used or have experience with.
    Templates with code are available for purchase for $50 USD
    www.easyexcela...
    code
    Private Sub Worksheet_Change(ByVal Target As Range)
    If Not Intersect(Target, Me.Range("A2")) Is Nothing Then
    Call access
    Application.EnableEvents = True
    End If
    End Sub
    Sub access()
    Dim barcode As String
    Dim rng As Range
    Dim foundVal As Range
    Dim diff As Double
    Dim rownumber As Long
    barcode = ActiveSheet.Cells(2, 1)
    If barcode (symbol for not equal"" Then
    Set rng = ActiveSheet.Range("a4:a150").Find(What:=barcode, _
    LookIn:=xlFormulas, LookAt:=xlWhole, SearchOrder:=xlByRows, _
    SearchDirection:=xlNext, MatchCase:=False, SearchFormat:=False)
    If rng Is Nothing Then
    ActiveSheet.Range("a4:a1005").Find("").Select
    ActiveCell.Value = barcode
    ActiveCell.Offset(0, 1).Select
    ActiveCell.Value = Date & " " & Time
    ActiveCell.NumberFormat = "m/d/yyyy h:mm:ss AM/PM"
    ActiveSheet.Cells(2, 1) = ""
    Else
    rownumber = rng.Row
    ActiveSheet.Range(Cells(rownumber, 1), Cells(rownumber, 10)).Find("").Select
    ActiveCell.Value = Date & " " & Time
    ActiveCell.NumberFormat = "m/d/yyyy h:mm:ss AM/PM"
    ActiveSheet.Cells(2, 1) = ""
    End If
    End If
    ActiveSheet.Cells(2, 1).Select
    End Sub

Комментарии • 77

  • @BarbHendersonconsulting
    @BarbHendersonconsulting  4 года назад +5

    Thank you so much for watching my video. In the code I have included in the description of video, I am not able to include square brackets . So when you see the (symbol for not equal to) replace it with for the code to run.

    • @rodrigopena6217
      @rodrigopena6217 4 года назад +1

      Great video. Although I tried to scan a bar code but it did not work, only worked when I entered the value manually. How to i enable the bar code scan to work.

    • @rodrigopena6217
      @rodrigopena6217 4 года назад +1

      Cell phone barcode scanner by using scan it to office app

  • @naresh90sharma
    @naresh90sharma 4 года назад

    Your all vedio very helpful for us
    Once again thank you so much

  • @wqip340
    @wqip340 3 года назад

    thank you soo much this is what ive been looking for

  • @neelamjangra4594
    @neelamjangra4594 4 года назад +1

    Dear Mam,
    Thank you so much for such a wonderful tutorial. it really helped me a lot. I need one more help from your side. Actually i want to display in and out time with date in a separate column. could you please guide me how to do that?

  • @GKTeach
    @GKTeach 2 года назад

    Thank you so much for such a wonderful and useful tutorial . it really helped me . based on your guide line I have try with barcode scanned but after barcode scanned we have to hit the enter key then only time stamp showing , can we make once scanned the barcode without hit the enter key barcode no should be go to down as order line .

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      normally you can set the barcode scanner to press enter once it has scanned the number. Check the settings on the scanner

  • @christinmahaffey8968
    @christinmahaffey8968 Год назад

    Hi! This is super helpful thus far and very close to what I've been looking for. I watched a couple of your other videos as well regarding calculating the time, but I'm struggling to apply the same concept here. As I am dealing with over 4000 students, I need the sheet to stay in the same format you have in this video, but to also calculate the total hours they have made up (clocked in and out) at the end. Any suggestions or help you can provide?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  Год назад

      the code on this video ruclips.net/video/hcL3q-kfUbY/видео.html might be helpful

  • @VuTran-st2cl
    @VuTran-st2cl 4 месяца назад

    Awesome Video, Just wondering if there is a way time stamp the same ID after it populate the info In B and C to go down to the next row instead of entering in D and E and going to the next collum thanks!

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  4 месяца назад

      you could have the name at the top and the in and out times below it. Just the way that you set up your sheet.

  • @JasonHDuctmann
    @JasonHDuctmann 2 месяца назад

    Is it possible to have 2 inputs to add an employee name as well? Ideally just use one column of IN/OUT and also have a column for the time between IN/OUT. That way an employee can log them selves to a job, have lunch and log back into a job and the time spent on it will be collected.

  • @soniaprashad4420
    @soniaprashad4420 3 года назад

    This is Extremely helpful to track employees time!
    I have one query, can the employee code/ID be highlighted when timing in/out?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  3 года назад

      rownumber = rng.Row
      rownumber.Interior.Color = RGB(255, 255, 0)
      and then at the end
      rownumber.interior.color =xlnone

    • @soniaprashad4420
      @soniaprashad4420 3 года назад

      @@BarbHendersonconsulting Thanks for the swift response. Unfortunately I didn't get it to work. Below is the code in use. It was tweaked a bit to suit our needs. Your guidance is appreciated!
      Sub access()
      Dim barcode As String
      Dim rng As Range
      Dim rownumber As Long
      barcode = ActiveSheet.Cells(1, 1)
      If barcode "" Then
      Set rng = ActiveSheet.Range("b3:b150").Find(What:=barcode, _
      LookIn:=xlFormulas, LookAt:=xlWhole, SearchOrder:=xlByRows, _
      SearchDirection:=xlNext, MatchCase:=False, SearchFormat:=False)
      If rng Is Nothing Then
      Range("b3").EntireRow.Insert
      Range("b3").Select
      ActiveCell.Value = barcode
      ActiveCell.Offset(0, 1).Select
      ActiveCell.Value = Time
      ActiveCell.NumberFormat = " h:mm AM/PM"
      ActiveSheet.Cells(1, 1) = ""
      Else
      rownumber = rng.Row
      ActiveSheet.Range(Cells(rownumber, 1), Cells(rownumber, 100)).Find("").Select
      ActiveCell.Value = Time
      ActiveCell.NumberFormat = " h:mm AM/PM"
      ActiveSheet.Cells(1, 1) = ""
      End If
      End If
      ActiveSheet.Cells(1, 1).Select
      End Sub

  • @pravindabir
    @pravindabir 3 года назад

    Thank u somuch👍

  • @arifahbahri7757
    @arifahbahri7757 4 месяца назад

    Thanks, this video helps me a lot. But can you assist me how to create a separate sheet for the barcode?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  4 месяца назад +1

      Take a look at this one, I am not sure this is what you need
      ruclips.net/video/g89fzCcPa9Q/видео.html

    • @arifahbahri7757
      @arifahbahri7757 4 месяца назад

      @@BarbHendersonconsulting Thank you! This is what I’m looking for 👍

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  4 месяца назад

      @@arifahbahri7757 Happy that I could help!

  • @nuraidamadhihahbintiazmank4113

    hi, thanks for the sharing. I want to know is it possible if i use barcode scanner instead of typing the id?

  • @Jonasvdbosch
    @Jonasvdbosch Год назад

    Hello Barb, is there a possibility to make this work for multiple days? My workers have to scan in and out every day. So something like a new sheet will open every day. Otherwise I will have 10 lines at the end of the week

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  Год назад

      Take a look at this video, I think this is what you need ruclips.net/video/hcL3q-kfUbY/видео.html

  • @mohdnaimbinahmadrazi6715
    @mohdnaimbinahmadrazi6715 11 месяцев назад

    Hi, why active sheet range got different? One is a4:a150 and another one is a4:a1005

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  11 месяцев назад

      they should both be the same ranges, just a slip in my typing ability😀

  • @brettsimpson2000
    @brettsimpson2000 Год назад

    Hey Barb. Great Tutorial, thank you. How would I change the code so rather than a new 'in time and date' in column D, it simply clears column C and overwrites the data in column B?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  Год назад +1

      replace ActiveSheet.Range(Cells(rownumber, 1), Cells(rownumber, 10)).Find("").Select
      with
      ActiveSheet.Cells(rownumber, 3).clearcontents
      ActiveSheet.Cells(rownumber, 3).select

    • @brettsimpson2000
      @brettsimpson2000 Год назад

      @@BarbHendersonconsulting Thank you, (and for the amazingly quick reply 🙂) I think I'm almost there however, that code only overwrites column C data rather than deleting B & C and adding the new data in Column B again. Im not sure what I need to add but basically, if data is already in column C, Delete B & C and add new data to Column B. Is this possible?

  • @ronanbartolazo1826
    @ronanbartolazo1826 2 года назад

    Hello! May I ask if I want to stop the excel sheet to accept entry after a number of scans?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      you must set up a column where they are no longer able to enter. for example if it reach column "H" then it will send an error message and exit sub

  • @utkarshvivek8083
    @utkarshvivek8083 3 года назад

    Hi Thanks for the code. Any clue why my code is not active and after every value on A2 only when I hit run macro does it return a time stamp. Any thing to do with my sheet settings?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  3 года назад

      If you install this code on your worksheet it will call the other code when a change is made. "Private Sub Worksheet_Change(ByVal Target As Range)
      If Not Intersect(Target, Me.Range("A2")) Is Nothing Then
      Call access
      Application.EnableEvents = True
      End If
      End Sub

  • @JoseMarquez-mh8ud
    @JoseMarquez-mh8ud Месяц назад

    How can i code this to calculate total in and out times?

  • @kentmaxian7139
    @kentmaxian7139 2 года назад

    How to lock the cell after you enter the barcode so that employee cannot edit the logs.Thanks

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      check out this video, ruclips.net/video/DlSl5Je-4HE/видео.html I do not know if it will work because you have the code on the worksheet to call the other program

  • @shriramuchiha4069
    @shriramuchiha4069 Год назад

    Can this be done in c programming

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  Год назад

      As far as I know VBA is the only code that works in Excel. The code is located in the description of the video. Feel free to copy and use it

  • @shrekyww
    @shrekyww 4 года назад

    Hi Mdm,
    How to I create a new row from an ID who had checked out previously instead of reflecting in the same row? Thank you.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  4 года назад

      What I have done in that instance is add additional columns for in and out. So that you are able to see all the in and outs for one day

  • @mariatenorio9672
    @mariatenorio9672 Год назад

    how can I buy this template?

  • @mod0521
    @mod0521 2 года назад

    Do you have a downloadable workbook as an example?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      The code is located in the description of the video

    • @mod0521
      @mod0521 2 года назад

      @@BarbHendersonconsulting thank you. Am having challenges getting the code to funciton. Was hoping there was a downloadable workbook that had the code in it that I could study and modify to our needs.

  • @muhammadmuzaffar899
    @muhammadmuzaffar899 Год назад

    what is "list separator" ?

  • @stephennored885
    @stephennored885 2 года назад

    The macro only works when I "Run Sub" manually from code view. How can I get the macro to run automatically once a number is entered into the cell?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      have you entered
      Private Sub Worksheet_Change(ByVal Target As Range)
      If Not Intersect(Target, Me.Range("A2")) Is Nothing Then
      Call access
      Application.EnableEvents = True
      End If
      End Sub
      on the sheet?

    • @stephennored885
      @stephennored885 2 года назад

      @@BarbHendersonconsulting Private Sub Worksheet_Change(ByVal Target As Range)
      'Application.EnableEnvents = True
      If Not Intersect(Target, Me.Range("A2")) Is Nothing Then
      'Application.EnableEnvents = False
      Call access
      Application.EnableEvents = True
      End If

      If ScannerTrigger = True Then
      'If the barcode scanner trigger is pressed
      Workbook.SetFocus
      End If

      End Sub

    • @stephennored885
      @stephennored885 2 года назад

      I also removed the "If Scanner..." and still doesnt work

  • @kristinbrown8787
    @kristinbrown8787 3 года назад

    How would you record a barcode entry that already exists in the data as a new row?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  3 года назад

      you would have to set it so that then it would find the next empty row and enter it there.

    • @aaronbaker7438
      @aaronbaker7438 2 года назад

      @@BarbHendersonconsulting Thank you so much for the video, but if the entry is already recoded twice how I can move the same entry to be recoded to the new row again?

  • @jhanel29SC
    @jhanel29SC Год назад

    this is exactly what i need, but i dont know how to start. it not working in my excel

  • @JK-je8no
    @JK-je8no Год назад

    I have everything working but I only need it to capture 1 check in and 1 check out and have the code stop working so I dont get an error. I cannot figure how to do that in the Code. Can someone help?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  Год назад

      I think that this is the video that you need ruclips.net/video/jOeEPO8xwr8/видео.html

    • @JK-je8no
      @JK-je8no Год назад

      @@BarbHendersonconsulting Thank you Barb! I have tried running that code but I need to check its Barcode Entry Column to A2 and have the code read from there. I am missing something. In this video the sheet calls calls the module but in the other video no module is called. Is this required?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  Год назад

      @@JK-je8no you must also insert the code on the worksheet, similar to the other one. When data is placed in the cell it will automatic run

  • @saravanane1804
    @saravanane1804 3 года назад

    Madam video very useful But i need department wise pls Help me Madam

  • @maktoomhassan1401
    @maktoomhassan1401 Год назад

    I will run the code it is working but it is not working automatically I have to run macro everytime Kindly guide

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  Год назад

      did you install this code on the worksheet?
      Private Sub Worksheet_Change(ByVal Target As Range)
      If Not Intersect(Target, Me.Range("A2")) Is Nothing Then
      Call access
      Application.EnableEvents = True
      End If
      End Sub

    • @maktoomhassan1401
      @maktoomhassan1401 Год назад

      @@BarbHendersonconsulting yes but it give error of ambiguous name detected: change_worksheet

  • @jennilyngaad735
    @jennilyngaad735 4 года назад

    Is this applicable in Google sheet?

  • @user-ye3bs6fl6b
    @user-ye3bs6fl6b Год назад

    Hey Barb, great video! I have one question I bet you can help me out with
    I had this code running (tweaked it a bit for my needs) and a week or so later I went back into my sheet and all the sudden I'm getting runtime error 91 : Object variable or with block variable not set
    I'm not sure why I'm all the sudden getting this error message as the code has been working and I didn't change anything. I attached most of it below (I have a function for each day of the week but I'll only attach the first part so you can get the idea)
    I'd appreciate any advice, thanks!
    Private Sub worksheet_Change(ByVal Target As Range)
    If Not Intersect(Target, Me.Range("A1")) Is Nothing Then
    Call monday
    Application.EnableEvents = True
    End If
    If Not Intersect(Target, Me.Range("F1")) Is Nothing Then
    Call tuesday
    Application.EnableEvents = True
    End If
    If Not Intersect(Target, Me.Range("K1")) Is Nothing Then
    Call wednesday
    Application.EnableEvents = True
    End If
    If Not Intersect(Target, Me.Range("P1")) Is Nothing Then
    Call thursday
    Application.EnableEvents = True
    End If
    If Not Intersect(Target, Me.Range("U1")) Is Nothing Then
    Call friday
    Application.EnableEvents = True
    End If
    End Sub
    Sub monday()
    Dim barcode As String
    Dim rng As Range
    Dim foundval As Range
    Dim diff As Double
    Dim rownumber As Long
    barcode = ActiveSheet.Cells(1, 1)
    If barcode "" Then
    Set rng = ActiveSheet.Range("b5:b500").Find(what:=barcode, _
    LookIn:=xlFormulas, LookAt:=xlWhole, SearchOrder:=xlByRows, _
    SearchDirection:=xlNext, MatchCase:=False, SearchFormat:=False)
    If rng Is Nothing Then
    ActiveSheet.Cells(1, 1) = ""
    Else
    rownumber = rng.Row
    ActiveSheet.Range(Cells(rownumber, 1), Cells(rownumber, 4)).Find("").Select