View Full Version : How to close a Form using a macro?


kaluapig
11-17-2004, 11:11 AM
I'am sitting here scratching my head in total confusion.

I have an action button in a form that runs a macro. This macro is a one-step macro to close the form I have open.

When I click the action button, the macro dues not run. An error message pops up that says:
This action can't be carried out while processing a form or report event.

If I was to just have the form open and run the macro button straight from the macro objects, it closes the form, no problem.

Can anyone provide me some guidance on how to close the form using a macrobutton?

Thanks all!

Nick

Newman
11-17-2004, 12:37 PM
I am not familiar with macros, but I think that you can't!
It would be like lifting a chair while sitting on it.
The only thing you could do with macros is open another form, and in that form close the previous one. But that would be very ugly.

I invite you to use the button wizard which could create some VBA code for you instead.

I hope that it helps!

kaluapig
11-17-2004, 01:43 PM
Will try..

Thanks!

Nick

kaluapig
11-17-2004, 02:04 PM
YOU ARE A GENIUS!!!

WORKS LIKE A CHARM NOW!

MANY MANY MAHALO's (FROM HAWAII)

NICK