Solved

'Action failed on AutoExec' error msg on app start-up

Posted on 2012-12-20
10
585 Views
Last Modified: 2012-12-20
when you open this access app, you get the below screen. how can this warning be avoided? (Action failed on AutoExec)

when you click close, then you get the second screen. (vba macro)

this started happening only 2 months or so ago, i am told.

thanks.
0
Comment
Question by:25112
  • 4
  • 3
  • 2
  • +1
10 Comments
 
LVL 65

Assisted Solution

by:Jim Horn
Jim Horn earned 250 total points
ID: 38709990
Define 'the below screen' and 'the second screen', as I don't see any screen shots.
0
 
LVL 84

Assisted Solution

by:Scott McDaniel (Microsoft Access MVP - EE MVE )
Scott McDaniel (Microsoft Access MVP - EE MVE ) earned 83 total points
ID: 38710023
Action failed on AutoExec
You would have to determine which action is failing in the AutoExec macro. If you can list those actions, we might be able to point you to some likely suspects.
0
 
LVL 5

Author Comment

by:25112
ID: 38710056
sorry i had not put comment for attachment, and it was not loaded.. here is the screenshot
2nd-screen.png
macro.png
0
 
LVL 5

Author Comment

by:25112
ID: 38710065
LSMConsulting, do you mean the error code? (2950).. or the code of the macro?
0
 
LVL 65

Assisted Solution

by:Jim Horn
Jim Horn earned 250 total points
ID: 38710070
If I'm interpreting this correctly, it's not an error, but the user's Office settings for Trust Center is not allowing any Access apps that have code or macros to execute those code or macros, and when the AutoExec macro fires on startup it blocks execution.

Below is the manual answer for Access 2010.   Also, afaik there is no way to programmatically pull this off, as this was intended to be a safeguard against viruses.

Give this a whirl on the pc that is generating the message (Access 2010)

(1)  Go to File menu, Options.  The Options window will appear.
(2)  Click on the Trust Center on the left, and hit the 'Trust Center Settings...' button.  The Trust Center window will appear.
(3)  Click on Trusted Locations, then click on the 'Add new location...' button.
(4)  Enter the path that the Access app lis in, and hit Ok.
(5)  Hit Ok a couple of times to close.

Close out of Access, then open the database, and it should go straight to the Main Menu.
0
Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

 
LVL 5

Author Comment

by:25112
ID: 38710083
when I open the app with Shift key, I get this screen only
2.png
0
 
LVL 47

Assisted Solution

by:Dale Fye (Access MVP)
Dale Fye (Access MVP) earned 167 total points
ID: 38710099
This is caused by Office security settings.  Since this appears to have begun several months ago, I assume that the version of Office in use on that computer was upgraded from 2003 or lower to 2007 or higher about two months ago.

The only way to circumvent this message is to designate the folder that the application resides in as a "trusted location".  Creating a "trusted location" will allow VBA code (and macros) embedded in any Office application that resides in that folder to run without first having to "enable" macros.

1.  Click the Office button in the upper left corner when Access is opened,.
2.  Click the "Access Options" button (bottom center of popup window)
3.  Click the "Trust Center" option in the panel on the left of the Access Options dialog
4.  Click the "Trust Center Settings" command button
5.  Click the "Trusted Locations" option in the panel on the left
6.  Click the "Add a new Location" button, then migrate to the folder where your application resides.

HTH
Dale
0
 
LVL 65

Assisted Solution

by:Jim Horn
Jim Horn earned 250 total points
ID: 38710100
>when I open the app with Shift key, I get this screen only
That's because opening it with the Shift key down bypasses the AutoExec macro.
Since no code is executing, it allows the file open, which then goes to a blank screen with all your objects listed.
0
 
LVL 47

Accepted Solution

by:
Dale Fye (Access MVP) earned 167 total points
ID: 38710118
Sorry, Jim.  Did not mean to repeat your post.

The other thing about the Shift bypass, if you look at your screen (not the image you posted), you should see a bar across the top of the Access window (probably right below the menu bar) that says something like:

Security Warning Certain content in the database has been disabled

This will be followed by a command button (Options) which pops up the Security Options dialog, which is the first image you provided.
0
 
LVL 5

Author Comment

by:25112
ID: 38710705
thanks a lot for your explanation!
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now