By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,790 Members | 1,430 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,790 IT Pros & Developers. It's quick & easy.

How call form from another form ?

P: 1
Hi friends
I have "login" form. My submit button checks username and password.I want this button also close "login" form and open another form which name comes from label caption. For example:
Expand|Select|Wrap|Line Numbers
  1. DoCmd.OpenForm " label11.caption "
But I get error. and cannot solve this.
Please help
Thanks in advance
Apr 3 '17 #1

✓ answered by NeoPa

You should understand that the quotes (") tell the compiler to treat the text within them as literal text, rather than what you want, which is to treat that text as a reference to where to find the string you actually want to use.

Lose the quotes and you should find it works. Assuming all else is set correctly of course.

Share this Question
Share on Google+
1 Reply


NeoPa
Expert Mod 15k+
P: 31,418
You should understand that the quotes (") tell the compiler to treat the text within them as literal text, rather than what you want, which is to treat that text as a reference to where to find the string you actually want to use.

Lose the quotes and you should find it works. Assuming all else is set correctly of course.
Apr 4 '17 #2

Post your reply

Sign in to post your reply or Sign up for a free account.