1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Solved: Microsoft Access 2007-2010: Stopping Automatic Saving On Data Entry Form

Discussion in 'Business Applications' started by joewill, Jan 24, 2013.

Thread Status:
Not open for further replies.
Advertisement
  1. joewill

    joewill Thread Starter

    Joined:
    Jan 17, 2013
    Messages:
    5
    I have a form to update the hardware of a PC for an asset database (see image attached), it features a main form which shows the current information for that computer and a subform which creates a new record for that PC with all the new information. The problem is that when i enter new information into the subform and click onto the main form it automatically creates and saves the new record which is what i want to stop.
    I would like the subform to save/cancel the data entry through the save and cancel buttons i have rather then it creating a new record automatically.
    Any help would be appreciated.
     

    Attached Files:

  2. OBP

    OBP

    Joined:
    Mar 8, 2005
    Messages:
    19,895
    joewill, welcome to the Forum.
    I do not understand why you are doing what you are trying to do.
     
  3. joewill

    joewill Thread Starter

    Joined:
    Jan 17, 2013
    Messages:
    5
    Because if the user decides to click off the subform while filling it in access creates an unfinished record which will clutter up the program with bits of random unfinished records which can't be undone even though the cancel button has the vba code "me.undo". Each update that is submitted is unique so if a computer is having problems we can look to see the previous versions of that computer and what has been changed.
    I want to use the buttons to submit and cancel updates so the user has the ability to submit a record when they decide it is complete rather than access deciding for them and creating a bunch of incomplete records.
     
  4. OBP

    OBP

    Joined:
    Mar 8, 2005
    Messages:
    19,895
    So if the user is satisfied with the record and "saves" it, does it create a new record in the Main Table?
    How does the user know which is the lastest data

    I created some VBA code for an "Audit Trail" of all changes made to the data, but it does not require new records in the Main table, only in the Audit Trail table.
     
  5. joewill

    joewill Thread Starter

    Joined:
    Jan 17, 2013
    Messages:
    5
    yes it creates a new record in the main table and each update has its own "install ID" which is also how the user knows which is the latest data; the highest install id is the most recent update. The form selects the newest record by using "order by" in the data properties which selects the id in descending order.
     

    Attached Files:

  6. OBP

    OBP

    Joined:
    Mar 8, 2005
    Messages:
    19,895
    Have you tried using the me.undo twice, once to cancel the last entry and once for the Record?
    The only othe rway know to do what tyou want is to use "Unbound" fields and the update is then controlled by VBA code.
     
  7. 20_2_Many

    20_2_Many

    Joined:
    Jun 29, 2012
    Messages:
    518
    Have you considered using Access Data Collection features? Your database can be setup with core tables for what concerns IT for the hardware and software, and what concerns the users themselves. Updates to any of it can be done emailing directly from Access, and the replies automatically update (merged in with existing data) or appended. Info that users do not care about and should not need to bother with like computer type, make, model, serial number, can be updated by emails to the IT crew from the database as well. Keeping fingers out of the database itself is always cleaner. We will always have people who think Ford or Chevrolet is a Model of car, and the Make is Detroit when they respond to forms.
     
  8. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/1086647

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice