Save records as you go (1 Viewer)

Tee2

Registered User.
Local time
Today, 07:57
Joined
May 28, 2015
Messages
23
Within the database I've been building I have a form that has ~30 fields. I have a fear that users will be very unhappy with me when the data they've entered gets lost. Perhaps I have built the database improperly (this is my first attempt) but it seems strange to me that a record isn't saved without user input (like going to another record). Also if the ESC key is pressed all the entered information is cleared. I don't like people being mad at me or the database I've created! Is there something I'm missing? Is there a way to save the record as you enter data or would that lead to poor performance? It doesn't seem that unreasonable to me to achieve this and other database software I've used does that by default.

I've tried searching for other posts on this topic but I've been unsuccessful so apologies if this is a redundant question. I must be searching for the wrong things.
 

spikepl

Eledittingent Beliped
Local time
Today, 15:57
Joined
Nov 3, 2010
Messages
6,142
Access does save the current record if you go to another record. Normally, that is. So you must have done something extraordinary to make Access not do so.
 

Tee2

Registered User.
Local time
Today, 07:57
Joined
May 28, 2015
Messages
23
Sorry if I wasn't clear. It does save when I go to another record. My issue is that is the only time it saves. What I'm asking is if there is a way to save as you enter the information.
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 06:57
Joined
Aug 30, 2003
Messages
36,139
This is one of those where you can't please everyone. You don't want the Esc key to undo the record; many if not most do. Many don't want the record committed until they're ready, you do. You can force a save at any point with

If Me.Dirty Then Me.Dirty = False

That's VBA code, goes here:

http://www.baldyweb.com/FirstVBA.htm
 

Tee2

Registered User.
Local time
Today, 07:57
Joined
May 28, 2015
Messages
23
Right, that is exactly what I'm looking for. Is there an event you can safely tie this to that would do this passively rather than require a user to click save? Thanks!
 

jdraw

Super Moderator
Staff member
Local time
Today, 09:57
Joined
Jan 23, 2006
Messages
15,411
I'm going to go back to your design. The things you are asking for are, as Paul said, a little unusual. Can you tell us about your database -- what is the subject matter?
What about your tables and relationships -- can you tell us or show a jpg of your relationship window? You may need to zip it before posting.

30 fields on a form is quite a few --- designers work toward 7 ( I saw that somewhere).

Do you really want to save partial records???
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 06:57
Joined
Aug 30, 2003
Messages
36,139
Right, that is exactly what I'm looking for. Is there an event you can safely tie this to that would do this passively rather than require a user to click save? Thanks!

You can put it in the after update event of key controls, or all controls if you want. It just seems...odd.
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 06:57
Joined
Aug 30, 2003
Messages
36,139
Tee2 said:
don't know if tying it to certain events would cause performance issues with the database.

It will certainly increase the traffic between the front and back ends, but in normal conditions I doubt it will be noticeable.
 
Last edited:

Tee2

Registered User.
Local time
Today, 07:57
Joined
May 28, 2015
Messages
23
Thanks, that's helpful. I guess how we use our database differs from how others use theirs. I can understand why partial records or constant saving would be a problem in many databases but in our case I don't see it being a problem.
 

Users who are viewing this thread

Top Bottom