Help opening a seperate form when a y/n box is clicked

kuebs

New member
Local time
Today, 18:29
Joined
Mar 6, 2002
Messages
5
I have a form that I want opened when a y is clicked in a y/n box. This subform would allow them to fill in details of the incident. I have a button to close the form, but can't get anything to work to have it open automatically.

Also, I would like it if this subform could present information from the previous form. Just one field, the sales order number field, but I don't know how to make that type of look up funciton. Thanks.
 
Look up the OpenForm action in Access VBA help. Also there is a useful help file called 'Synchronize records between two forms'.
You can put this code behind the On Click event of your y/n checkbox: DoCmd.OpenForm "FormName",,,WHERE CLAUSE,,acDialog (popup)
Use the WHERE CLAUSE to specify how your new form opens (probably opening it to the same person's record).

As far as the sales order number, you can I believe pull that into an unbound text box just by setting its record source to =Forms.[MainForm].[SalesOrder], as long as the main form is open. If not, look into Dlookup in the archives or Access help.

HTH,
David R


[This message has been edited by David R (edited 03-18-2002).]
 

Users who are viewing this thread

Back
Top Bottom