Sue,
The more I talk about access, the more apparent it becomes that, at least
around here, I shouldn't talk very often about it.
I have three points. Hopefully someone will jump in and correct all of them.
1. I think this is happening: you hit "addnewrec" button, and go to a new
record. Your application adds some fields "automatically (programatically).
These additions are enough, to constitute a "record". When you hit
"addnewrecord" again, access saves your "current" record (which consists
solely of those pieces of data automatically added when you arrived), and
then goes to another "new record". Generally speaking, you don't have to do
anything to "save" a record. The mere act of moving to another record or
closing a form will save a record. Adding a "save" button doesn't, in and of
itself, change that fact.
2. It wouldn't happen quite like it is for you EXCEPT for I believe the
code you posted that attempts to force users to add information for all those
fields is ineffective. I can't say for sure how it SHOULD be done, but I
think I'd just make all the fields you want to require "required" fields in
the underlying table.
Regardless, your relevant code says "IF addnewrec.enabled Then" doesn't seem
like it could possibly be right, mainly because "enabled" must be true or
false. I'm not sure that even if you corrercted that it would say what you
want it to say, but I think it's almost surely created a situation where all
that other code below it in the "then" portion is basically meaningless.
Therefore, you aren't requiring people to fill out all those fields after
all. If you WERE requiring all those fields to be completed, then you
wouldn't be able to just hit the "addnewrec" button to create multiple
meaningless documents because the second time you hit it you'd be told "no,
get back over here and fill out these fields on this form FIRST, then you can
go to a new one".
3. I think you could probably fix the problem by getting rid of all your
attempts to automatically add data to any new record created. Specifically,
I have a feeling that that first part of your code that creates an ID tag
based on a couple of possibilities is what's causing the problem. You could
cut the code out and paste it into a word/text document, remove any reference
to it in the properties window of your form, and then see if you are still
having the problem. It may be some other instance of automatically added
data that's causing the problem, so don't dismiss the notion just because you
find out it's not that particular instance.
This is all speculation, but it's what I'd focus on if I were
trouble-shooting the issue with one of my apps.
I hope something I've said spurs you to figure out what the issue is, or
angers someone else into responding with some quality info for you
CW