Opening a Form with a Subform in Data Entry Mode

L

LeLe

I want a single Form with a subform to be available in both Data Entry as
well as edit mode. I think I know how to use the DoCmd Open form in Data
Entry but I don't understand about the subform. How do I make sure it opens
in Data Entry mode or edit mode as needed?

Thanks
 
T

Tom Wickerath

Hi LeLe,

You shouldn't need to worry about how the subform opens, as long as you have
the Link Master Field(s) / Link Child Field(s) set correctly. Just worry
about opening your main form in either edit or add new mode, using the
correct optional parameter of the DoCmd.Openform method, ie:

DoCmd.OpenForm "FormName", View:=acFormAdd
versus
DoCmd.OpenForm "FormName", View:=acFormEdit

where FormName is the name of your main form.


Tom Wickerath
Microsoft Access MVP
http://www.accessmvp.com/TWickerath/
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________
 

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