Saving information on form with bound fields by clicking button.

J

jhanby1

I have a form called fsubCaseDetails that gets information from another
form fsubCaseSearch. Once the user double clicks a case in the lstCases
on fsubCaseSearch, fsubCaseDetails becomes visible and gets populated
with the information for the selected case.

The way I have fsubCaseDetails configured is to allow the user to
change the data in several textboxes and combo boxes by clicking
cmdEditCaseInformation. This command button turns AllowEdits to True,
and the user can make any changes they want, but they are directly to
the database b/c all of the fields on the form are bound to the
database. To turn off this edit mode, they click another button that
turns AllowEdits to False. My questions are this:

1. I have other forms that use this funcitonality perfectly, but for
some strange reason, the Edit Case button doesn't allow changes to be
made. Any ideas?

2. More importantly, I want the user to be able to be able to make alll
the changes he/she wants, but not take immediate effect to the
database. I am trying to avoid using SQL UPDATE statements for this
functionality, because I would rather not make the fields unbound. I
now have fsubCaseDetails populate its data by setting the RecordSource
equal to a record from tblCases WHERE tblCases =
Forms!frmMainPage!fsubCaseSearch!lstCases. Any ideas?

Thanks for all the future input!
 
S

Sandra Daigle

To answer the first question I would really need more information about the
form on which the Edit Case button does not work. What code are you using in
the click event of the button? Are you sure that the code is actually being
fired (check the property sheet and make sure that "[Event Procedure"] is in
the OnClick property)? Is the Recordsource query for the form updatable?

On the second question, AFAIK there is no easy or built-in way to stage
updates to a table. Either you use bound forms and the updates are immediate
or you use unbound forms and control the updates using code. There are
however, procedural ways to handle it. One way is to add to your table a
status field. Through your application you can create and maintain different
record statuses that you use to filter the new/pending record from the
records that you (currently) want saved.
 

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