JenniferD
01-14-2002, 07:57 AM
I have an application which starts with a Main Screen. From there, you open a Form where the user selects a Job they want to edit. Once they select a Job, it then opens an Edit Form and from there, they can go to the 'Select For Print' Form which allows them to chose records to print before actually printing. The problem is that I am not controling the forms efficiently.
Currently, I close most of the forms once the user moves on, but then I have a BACK button on most forms which allows the user to step back one form. When they do so, I was re-opening the forms (DoCmd.OpenForm). I think this is eating memory when I am constantly opening and closing forms. I want to understand how to just hide them and reload them when the user presses BACK rather then open and close. Here is the hierarchy so you can better understand the flow:
Main Screen (cmd button to open Job Select)
Job Select (cmd button to open Edit Job, cmd to go back to main)
Edit Job (cmd button to open Select for Print and cmdbutton to go back to Job Select)
Select for Print (cmd button to open Report and cmd button to go back to Edit Job and one to return to Job Select)
The Edit Job and Select For Print forms are being sent a filter in the DoCmd WHERE clause to filter out only the job in question. I wasn't sure how to hide/unhide or actuivate/unactivate the forms and then refresh with the new filters each time.
I guess what I am asking is when the user goes to the Job Select Form from the Main Screen, I want to just hide the Main screen so they can easily go back to it later...then from the Job Select, be able to go to the Edit Job and hide the Job Select so it can be returned to.
The other tricky part for me is then going to the Select For Print screen... currently, i have the Select For Print just opening OVER the Edit Job screen so that when the user clicks the BACK button from the Select For Print, it just closes the Select For Print which puts them back onthe same record in the Edit Job. However, if they make a change and then click the 'Select For Job', I am REOPENING using the DoCmdOpenForm which I think will be slow and eat memory.
What I would ideally like to do (if it is the most efficient) is just open all of the forms needed, and then just pass the filter each time I call the form and hide the others. Which property do I use for this type of control? (activate, hide, load, etc)....Also, what is the proper syntax for changing Form properties from within a different form?
I am sorry this is confusing...if I left anything out (like the fact that I am using Access 2000 ), just let me know.
Thanks for any help.....and thanks to anyone who can understand what I am asking here :)
Currently, I close most of the forms once the user moves on, but then I have a BACK button on most forms which allows the user to step back one form. When they do so, I was re-opening the forms (DoCmd.OpenForm). I think this is eating memory when I am constantly opening and closing forms. I want to understand how to just hide them and reload them when the user presses BACK rather then open and close. Here is the hierarchy so you can better understand the flow:
Main Screen (cmd button to open Job Select)
Job Select (cmd button to open Edit Job, cmd to go back to main)
Edit Job (cmd button to open Select for Print and cmdbutton to go back to Job Select)
Select for Print (cmd button to open Report and cmd button to go back to Edit Job and one to return to Job Select)
The Edit Job and Select For Print forms are being sent a filter in the DoCmd WHERE clause to filter out only the job in question. I wasn't sure how to hide/unhide or actuivate/unactivate the forms and then refresh with the new filters each time.
I guess what I am asking is when the user goes to the Job Select Form from the Main Screen, I want to just hide the Main screen so they can easily go back to it later...then from the Job Select, be able to go to the Edit Job and hide the Job Select so it can be returned to.
The other tricky part for me is then going to the Select For Print screen... currently, i have the Select For Print just opening OVER the Edit Job screen so that when the user clicks the BACK button from the Select For Print, it just closes the Select For Print which puts them back onthe same record in the Edit Job. However, if they make a change and then click the 'Select For Job', I am REOPENING using the DoCmdOpenForm which I think will be slow and eat memory.
What I would ideally like to do (if it is the most efficient) is just open all of the forms needed, and then just pass the filter each time I call the form and hide the others. Which property do I use for this type of control? (activate, hide, load, etc)....Also, what is the proper syntax for changing Form properties from within a different form?
I am sorry this is confusing...if I left anything out (like the fact that I am using Access 2000 ), just let me know.
Thanks for any help.....and thanks to anyone who can understand what I am asking here :)