Help with OpenForm

  • Thread starter Thread starter Ig
  • Start date Start date
I

Ig

Hi,

DoCmd.OpenForm "MyForm", , , , acFormReadOnly

Is it possible to know in MyForm's code what parameter acForm... it was
called with?
(assuming that I don't know design settings of AllowEdits,AllowDeletions and
AllowAdditions of MyForm)
Thanks
 
Hi:

The last argument in DoCmd.OpenForm is OpenArgs.

DoCmd.OpenForm "MyForm", , , , acFormReadOnly,"AnyTextYouWant"

In your Form MyForm you can check OpenArgs with
If Me.OpenArgs = "AnyTextYouWant" then

Regards,

Naresh Nichani
Microsoft Access MVP
 
is there any other (non-artificial) way to know about passed parameters?
 

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

Similar Threads

FindFirst Criteria Problem 1
print landscape (VB) 5
One page limit via print macro 4
Database security 1
Shorten Forms!Myform! to frm. 5
Recordset FindFirst Not Working, Why? 3
Form closing problem 2
Audit Trail 1

Back
Top