Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

AutoExec macro, A97?

6 views
Skip to first unread message

MLH

unread,
Jul 4, 2005, 2:52:15 PM7/4/05
to
Did A97, perchance, do away with the need for
an AutoExec macro to initiate an autoexec sequence
for databases? Or, must we still suffer with that hideous
macro?

Tim Marshall

unread,
Jul 4, 2005, 2:59:50 PM7/4/05
to
MLH wrote:

I use an opening form and the on open event of that form. If I just
want the procedures to do stuff but don't want that particular form up,
after all the procedures run by the on open event are done, I plop in
Cancel = True.

This does pretty much the same as autoexec.

--
Tim http://www.ucs.mun.ca/~tmarshal/
^o<
/#) "Burp-beep, burp-beep, burp-beep?" - Quaker Jake
/^^ "Whatcha doin?" - Ditto "TIM-MAY!!" - Me

Douglas J. Steele

unread,
Jul 4, 2005, 3:09:42 PM7/4/05
to
While I'm not a proponent of macros, I certainly don't see what's so
"hideous" about the autoexec one!

In Access 97 (and, in fact, all subsequent versions), you have two startup
options: you can use an autoexec macro, or you can specify a form to be
opened at startup. I'll often use an autoexec macro, though, with a single
command: to run a VBA routine.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

"MLH" <CR...@NorthState.net> wrote in message
news:u71jc15esc8npbbif...@4ax.com...

MLH

unread,
Jul 4, 2005, 4:15:34 PM7/4/05
to
There ya go! I like it.
xxxxxxxxxxxxxxxxxxxxxxxxxxx

MLH

unread,
Jul 4, 2005, 4:19:09 PM7/4/05
to
Ha! I guess I overdid it with the "hideous" parameter. Actually,
its from back in my original days first working with Access 2.0.
I didn't know anything about Access Basic and was afraid to
start with it. So, I did everything in macros for about a year.
Finally, I bit the bullet. IT TOOK ME YEARS to port over all
the macros crap I had built. At the risk of being scorned, I really
do think they're hideous!

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

Albert D. Kallal

unread,
Jul 4, 2005, 4:28:41 PM7/4/05
to
It is still there, and for compatibility, you would not want to change
this..as you would then break zillions of databases.

As others have mentioned, using the startup form is often the solution. (the
option is in tools->startup).

In some cases, such as a back end file, when users click on it, I give them
a message about not having permissions, and then shut down ms-access. (this
keeps them out of the back end..and no security is needed).

In this case, since I do NOT need a form, nor do I want to use the preferred
startup setting in tools->startup, then I do use a macro.

that macro simples has:

Msgbox
Message : You do not have permissions to run this file
beep: yes
Type:critical
Title Cannot run

And, then the next line of the macro is

Quit
options:exit

So, in the above, I don't have to add a code module, I don't have to add a
startup form. Yet, I get a nice message telling the user they can't use the
back end file. So, in this example, a macro is preferred. No forms, no
modules, and not even a worry about broken refs, or having code to run. The
only thing I needed to add was the above autoexec macro...

you can also use the runcode "action" in a macro, and it can call any
function you have in code....


--
Albert D. Kallal (Access MVP)
Edmonton, Alberta Canada
pleaseNOO...@msn.com
http://www.members.shaw.ca/AlbertKallal


SilvrT

unread,
Jul 4, 2005, 8:12:19 PM7/4/05
to
KEEWWWLLLLLLL !!!!!!

Never thought of this before... gonna use it ALWAYS now! LOL

SilvrT
Burnaby, BC, Canada

0 new messages