Page 3 of 4 FirstFirst 1234 LastLast
Results 31 to 45 of 53
  1. #31
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41


    Quote Originally Posted by June7 View Post
    No, it doesn't. Can run an UPDATE sql action. Still need record id to do find record in table.

    Edited my previous post quite a bit. Might review again.

    I had to rename the textbox to tbxID.

    All works.
    Still getting the Compile error - 'Method or data member not found'

  2. #32
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    Sounds like you have not correctly renamed the textbox.

    All I did was download your db and do the described edits. Form works.

    Did you download the revised db offered by Steve?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #33
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    Quote Originally Posted by ssanfu View Post
    I looked at your dB and became a little frustrated with the (lack of) naming convention..... so I changed a lot of names.

    As noted, cannot check out as the dB stands because the form is in data entry mode. You could use VBA to find the already entered record for a badge number, job number, check in date, then set the check out date/time.

    I set the global variables in the button click. Seemed easier than using more code in the submit button.
    I removed the requires setting for the visitor badge number. If you have a work badge, how would you also have a visitor badge??
    I renamed a lot (if not all) controls and most of the field names. I added PK/FK relationships. and properly (IMO) set up the combo boxes.
    I added the prefix "frm" to the form name. Not real good idea to have multiple objects with the same names (table named "Initial" and form named "Initial").
    I also removed the Layout formatting.


    Attached is the modified dB..
    Just saw your post, I will open the Db and see what it looks like and try to clear some of my confusions, lol. Sorry for the irritants, novice says it all but trying to learn properly from you guys and you all have my utmost respect for what you deal with.

  4. #34
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    i just responded to him, opening it as we speak.

  5. #35
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    Ok, the form does work as it is; Steve or June7, I am really trying to streamline the check out process with them choosing the check out button, entering their ID and updating their check in record with check out info. Is it as easy as accessing the users most recent record via something like 'Select from 'form' where tbxID.....'?

  6. #36
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    Let's presume if everything works properly, an employee will only ever have 1 record with CheckOut field Null and CheckIn should never be null so code can update the record with:

    CurrentDb.Execute "UPDATE Initial SET CheckOut = Now() WHERE BEMSID = " & Me.cbxSelectEmployee & " AND CheckOut Is Null;"
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  7. #37
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    Well if that ain't some shit!! I walked away for 10 minutes and someone came by and stole my usb card from the pc 'under' my desk. All of my database work, gone to some freakin theives!!

  8. #38
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    You know, I have you guys to thank for having me share it with you all. I almost forgot that I put it out there. I may have to put some other stuff back in it but at least I still have it. June7, I will give that a try as soon as I can get back to where I was. Thanks again everyone for everything!!!

  9. #39
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    Quote Originally Posted by June7 View Post
    Let's presume if everything works properly, an employee will only ever have 1 record with CheckOut field Null and CheckIn should never be null so code can update the record with:

    CurrentDb.Execute "UPDATE Initial SET CheckOut = Now() WHERE BEMSID = " & Me.cbxSelectEmployee & " AND CheckOut Is Null;"
    This would be in the Submit event correct? This is great, but...., how do I get them to just enter their ID after hitting Check Out so that it knows whose record to update, you follow what I'm trying to do? I don't want them to have to re-enter all of the information again. Is this possible with my design?

  10. #40
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    Re-enter what information? All they need to do is select name/id from an unbound combobox.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  11. #41
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    Quote Originally Posted by June7 View Post
    Re-enter what information? All they need to do is select name/id from an unbound combobox.
    So just create a combo box with the id's pulled from the initial table?

  12. #42
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    That's the suggestion.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  13. #43
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    I'll give that a shot, thanks!

  14. #44
    bigot is offline Advanced...ish
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2014
    Posts
    37
    Quote Originally Posted by fspata View Post
    So is this just for my Submit button or is this a whole new form to be created, maybe I misunderstood you earlier?? Also, are you referring to the Submit button being the all-in-one button, Check In/Out? Only reason I'm asking is because they have a line up of people behind them at checkout so I'm trying to streamline the checkout process to get people out faster with the scan Id, access the 'In' record and update it with checkout info.
    I wrote that assuming you are using that ID scanner/computer just for check in/out. The way I suggested doing it would allow the staff to just walk up to it, scan their id, and be checked in/out. There would be no need for mouse/keyboard. If that is not the case, don't make the button default.

  15. #45
    fspata is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Oct 2015
    Posts
    41
    Quote Originally Posted by bigot View Post
    I wrote that assuming you are using that ID scanner/computer just for check in/out. The way I suggested doing it would allow the staff to just walk up to it, scan their id, and be checked in/out. There would be no need for mouse/keyboard. If that is not the case, don't make the button default.
    Actually there is more info that would be entered; location, supervisor, etc.

Page 3 of 4 FirstFirst 1234 LastLast
Please reply to this thread with any new information or opinions.

Similar Threads

  1. New record condition
    By rosscortb in forum Access
    Replies: 3
    Last Post: 07-06-2015, 07:19 AM
  2. Where Condition
    By NISMOJim in forum Programming
    Replies: 4
    Last Post: 04-09-2014, 11:10 PM
  3. Help with using the AND condition
    By ssturges in forum Access
    Replies: 1
    Last Post: 11-25-2012, 12:36 AM
  4. Like condition for 1 column help pls!
    By stodd in forum Queries
    Replies: 1
    Last Post: 03-14-2010, 01:51 AM
  5. How to use IIF condition
    By nshaikh in forum Queries
    Replies: 4
    Last Post: 09-12-2008, 01:23 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums