Open Form/Close Form VBA

D

DD

I use the code below to close one form and open another on
click of a command button but it operates kind
of "clunky". My open event is set to maximize the form I
am opening but while one form opens and the other closes
the user sees it open non-maximized and then it maximizes
while they watch. I have tried reversing the order of the
lines below to first close the one form and then to open
the other but still the same unpleasing visual results.

DoCmd.OpenForm "frm_Sales", acNormal, "", "", acReadOnly,
acNormal

DoCmd.Close acForm, "frm_Main"

Thanks in advance.
 
B

Bas Cost Budde

DD said:
I use the code below to close one form and open another on
click of a command button but it operates kind
of "clunky". My open event is set to maximize the form I
am opening but while one form opens and the other closes
the user sees it open non-maximized and then it maximizes
while they watch. I have tried reversing the order of the
lines below to first close the one form and then to open
the other but still the same unpleasing visual results.

DoCmd.OpenForm "frm_Sales", acNormal, "", "", acReadOnly,
acNormal

DoCmd.Close acForm, "frm_Main"

Thanks in advance.

Put docm.echo true and docmd.echo false around the statements?
 

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