form selection

L

Lapchien

Struggling with this (still!) - we have a db with several forms. Lets call
them frm_A, frm_B and frm_C.

The front screen (main form) of the db will prompt for an 'account number'
(stored in another table). If the user enters, say 5555, then frm_A will
open. If they enter 9999 frm_B will open, etc.

My 'account' table has 2 fields, Code, and Who (account number and name).
I've bound this table to the startup form.

How do I get the forms to open from account codes entered?

Thank You
Lap
 
L

Lapchien

A bit further on -

Private Sub Command2_Click()
DoCmd.OpenForm Me!Text9
End Sub

Text9 = account name (and form name).

However, if the user selects an acount number that is not in the table can I
have a 'friendly' error, and not just an End/Debug message?

Thanks
 

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