macro and form problem

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi, I have a problem here, I have a macro that close a form and open the same
form again (so the form is refreshed), my form is in datasheet view, but
when I run my macro, the form appears as single view, after I run a macro I
cheked the propierties of my form and the datasheet view is selected, why is
happening this???
 
Hi, I have a problem here, I have a macro that close a form and open the same
form again (so the form is refreshed), my form is in datasheet view, but
when I run my macro, the form appears as single view, after I run a macro I
cheked the propierties of my form and the datasheet view is selected, why is
happening this???

1) Whenever you open a form from an event (or a macro) on a form, you
must always open it explicitly in datasheet view.
Set the View argument of the Macro to Datasheet.

2) It really isn't necessary to close and re-open a form to refresh
the data. Without knowing more of your set up, you can use the Refresh
method and/or the Requery method to refresh the form data.

Look them up in VBA help.
 

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