How to check for Open Form with vba

  • Thread starter Thread starter John Michael
  • Start date Start date
J

John Michael

How do you check for an open form with vba.
I'm trying to requery a subform with the below state ment and it only works
if the form is open.
Forms![Open Transactions]!ctrlOpenTransactionsSubform.Requery

Thanks
John Michael
 
Try:
If CurrentProject.AllForms("Open Transactions").IsLoaded Then

If you are using A97 or earlier, you can use SysCmd(). Open the Northwind
sample database, and grab the IsLoaded() function from the utility module.
 

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

Back
Top