Run Macro

uksoldier

Registered User.
Local time
Today, 20:08
Joined
Jan 26, 2003
Messages
17
Ive created a macro to open a Welcome Message. On clicking the OK button the message will close and the Switchboard will open up.

How do I get that macro to run when I open the DBase ? Ive looked on Startup but cant find it there.

Thanx
 
In addition to Rich's answer -

another option is, if the welcome message is a form - click on tools>>>>startup - there's a box there for selecting a form you want to show when the Db is opened.

Col
:cool:
 
COLIN

Thanx Rich.... and Thanx Colin.... As you were posting your reply I created a form with a welcome graphic, then created a command Button called OK with a macro behind it to open the Switchboard when OK is clicked... Start up opens the Welcome Form, Data Entry clerks clicks ok and the main switchboard opens....just trying to work on closing the welcome form when the switchboard opens... confused ?!! lol
 
Delete the macro from the OnClick event of the ok button.

Select EventProcedure

Put this code in

Me.Close
DoCmd.RunMacro ("YourMacroNameHere")

Then the welcome screen will close and the macro will open the switchboard.

Just to confuse the issue you could have the welcome screen on a timer for say 5 or 10 seconds then close on its own and open the switchboard.;)

Col
:cool:
 
COLIN

You were doing so well now you have baffled me...

I selected EventProcedure clicked on the ... buttons and typed in what you said... but I got error messages about the Me Macro

Ive had these before and I fear that Im being dim or missing something... can you expand please ?

TyVm
 
Its not Me Macro

Its 2 different commands

Me.Close

DoCmd.RunMacro ("YourMacroNameHere")


Col
 
Hi UK SOLDIER,

Not sure if someone's already posted you a reply on this, but basically you name your macro AUTOEXEC. When the data base opens it will automatically scan for this and open it first.
 

Users who are viewing this thread

Back
Top Bottom