Modal forms

stevenb82

Registered User.
Local time
Tomorrow, 06:05
Joined
Nov 28, 2012
Messages
28
I have three modal forms set up. The are options for when a user wants to add something to my database.. I have three tables, cities, states, countries. The reason being that I have multiple tables which all use these tables. What I have set up is if a user trys to enter an address for a city that is not in the cities table, there is a button which opens a modal form so that they can add that city plus p/code to the cities table. What there then is on the add city modal form is a button that allows the user to add a state in the event that the state the new city is in has not yet been added to the state table..

When one modal opens another, is there any way to close that modal with the same button?
 
In the button event, first close the current modal form, then open the modal form your wish.
Like that:
DoCmd.Close acForm, "YourFirstModalForm"
DoCmd.OpenForm "YourNextModalForm"
 
I don't know if modal forms behave the same way as regular forms but I have had problems if I did not open the new form first and then close the old form.
It seemed to loose the next action when the form was closed.
 
In the button event, first close the current modal form, then open the modal form your wish.
Like that:
DoCmd.Close acForm, "YourFirstModalForm"
DoCmd.OpenForm "YourNextModalForm"

Thanks for that mate..
 

Users who are viewing this thread

Back
Top Bottom