How to do a Search Form !!!! (1 Viewer)

vividor

Registered User.
Local time
Yesterday, 21:35
Joined
Aug 5, 2002
Messages
31
Hey guys, can some one help me on understanding how to make a search form.

I have one big table named(BSA-Report) and a data entry form named(Quartely Report). I would like for the user to have the option to finish typing the report later, so I added a buttom at the bottom of the form for the user to save the record and close the form.

Now, I would like to have a buttom on a Search Form so the user can get back to the same report and completed. I am going to use two combo boxes and the name of the fields are( "Quarter and Unit Location").

I tried several times but I can not make it work.
Can some one explain to me, thanks.
 

Oldsoftboss

AWF VIP
Local time
Today, 11:35
Joined
Oct 28, 2001
Messages
2,499
Perhaps make a seperate table where the record no or report name could be stored

Then on your 'buttom' use a Dlookup to find the reference point.
Dave
 

jimbrooking

Registered User.
Local time
Yesterday, 21:35
Joined
Apr 28, 2001
Messages
210
The way I've done this is a little harder to code, but very nice for the user.

First, define a form with a recordsource the table Dave/oldsoftboss suggested. The table would have the value of your "Quarter and Unit Location" combo boxes for its two fields. (This is NOT the same as your BSA-Report table: It's a new table to save these combo box values when the user exits.)

Add two combo boxes to this new form, with row sources the quarter and unit location, taken from the "remember location" table. Bind these combo boxes to the corresponding fields in the new "remember location" table.

On this same form, add as a subform the big, hairy Quarterly Report form, and set the parent/child relationships between the master form and the sub form so the values on the subform correspond to the combo boxes on the main form. You will need to do something special to add a new record to the Quarterly Report table, because if you just add something new to one of the combo boxes on the main form, there won't be a corresponding record in BSA-Table and you will get an ugly screen the user can't cope with.

When the user decides to go home for the day in the middle of a report, s/he can just close the database - all the data on the sub form will be saved in BSA-Table, and the values in the main form combo boxes will be saved in the "remember location" table. When the user resumes next day, opening the form will load the main form combo boxes, then load the subform with the partial data entered previously, and the user never had to do anything special to save and restore/resume.

If you are doing any form field validity checking, either explicitly in the form's BeforeUpdate event or implicitly through the BSA-Table field definitions, an interruption like this could cause problems if required fields are not yet entered.

Jim
 

Users who are viewing this thread

Top Bottom