Complex form popup problem: warning...longwinded

  • Thread starter Amy Blankenship
  • Start date
A

Amy Blankenship

I have a form that allows my client to input scenarios to run in an online
course. Each scenario has a series of forms to be filled out, so I have a
main form that allows the user to fill out the scenario information, then
buttons that pull up blank versions of each form. The definition of the
blank is defined through a set of related tables, so I had to use an
approach similar to this to make it work:
http://groups.google.com/group/microsoft.public.access.queries/msg/7b1eace22c007082?hl=en.
To summarize, I had to make an updateable left join query in order to
provide the "blanks" to be filled in, then used it as the recordsource for a
popup form.

This essentially means that until the blank IS filled out, there's no actual
record in the form (the record shown in the form is reflecting the left side
of the join--nothing exists now on the right). As long as that's as complex
as it gets, everything is fine. However, each field has a button that pops
up yet another field that allows you to fill in data to be used in the
review/feedback part of the course. If a user fills in at least one field
in a blank record, then manually switches to another record or closes the
form, thus saving the record before opening the third form, everything is
still fine.

However, if this does NOT happen, then the first thing that happens is that
the filter expression that is supposed to either show an existing related
record in the form or create a new record fails, because the fields
providing the data for the filter is null. So, if I force data into those
fields when the command button is clicked and save the record
programmatically, then that part of it works. However, when the form opens
all the values are null.

The majority of the fields in the query that are the recordsource of the
failing form are fields that either belong to the scenario (definitely
stored and saved) or the form definitions, again long ago stored. The
remainder belong to the new record that was programmatically saved. If I
run the same query manually at that point, the entire record is there.

Can anyone point me to some things I can try to get this to work? Making my
users manually navigate back and forth before they press the button is not
optimal. But I don't have another 8 hours to work on this.

There is a lot of code making this work and a lot of queries involved, so if
you need specific information to answer the question please don't hesitate
to ask. I just didn't want to bog down the post with a bunch of stuff that
might not be relevant.

Thanks!

Amy
 
A

Amy Blankenship

I'd like to thank everyone for their heroic answers to help me. Despite the
great lengths the good folks of this newsgroup went to to address my
concern, I stumbled over the answer myself. I inserted a command button for
saving the record, then copied the code out of that button into the existing
command button that launched the other form. Problem solved.

Thanks again!

-Amy
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top