Results 1 to 3 of 3
  1. #1
    Robyn_P's Avatar
    Robyn_P is offline Competent Performer
    Windows 8 Access 2010 32bit
    Join Date
    Nov 2017
    Posts
    150

    Allow edits but prevent content being entirely deleted. Datasheet form


    Hello again. I have a very simple datasheet bound form for data entry. People make mistakes with the data so I want people to be able to go in and directly edit the data. However a couple of times now someone has gone in and decided that a record is no longer needed and just deleted the data contained in it. This is not good. The records may be already used elsewhere and I can't fix it up if I don't know what the original data is, so what I want is a way to prevent people leaving the field value as NULL after their edits. I'm thinking something like copying the original data to a hidden text box in the gotfocus event and then in the after update checking for null and if found, copying the original data back and displaying a warning message explaining why this is happening. Do you think that would work? Can you think of a cleaner method? If a record genuinely isn't needed any more, I need them to delete the whole record not just the field values. Thank-you

  2. #2
    davegri's Avatar
    davegri is offline Excess Access
    Windows 10 Access 2016
    Join Date
    May 2012
    Location
    Denver
    Posts
    3,741
    How about setting the 'Required' property to YES, and 'Allow zero Length' property to NO in table design for each field?
    Last edited by davegri; 08-07-2018 at 08:50 AM. Reason: more

  3. #3
    Robyn_P's Avatar
    Robyn_P is offline Competent Performer
    Windows 8 Access 2010 32bit
    Join Date
    Nov 2017
    Posts
    150
    Yep, that work fine. As a side effect noticed I have a numeric field set as type text in my table. That's silly, don't worry I know how to fix that. Thought there must be a better way. Thanks!

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 3
    Last Post: 02-06-2018, 02:40 PM
  2. Replies: 9
    Last Post: 03-04-2017, 07:43 PM
  3. Replies: 4
    Last Post: 11-21-2012, 10:11 PM
  4. Replies: 3
    Last Post: 09-07-2012, 12:50 PM
  5. Replies: 1
    Last Post: 03-03-2011, 09:32 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