Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Disable excel warning screens

Posted on 2001-08-03
11
1,053 Views
Last Modified: 2008-02-26
Within Excel there is a check box under

TOOLS>OPTIONS>GENERAL TAB>Macro virus protection

that by default is usually enabled.  This produces a warning dialog box anytime you open a workbook that contains VBA.

I am currently writing an application within excel VBA that executes as soon as the workbook is open. I wish to prevent the macro virus protection dialog warning from activating when I run my spreadsheet.  In effect I wish to uncheck the macro virus protection in the general dialog box programmatically, since it will be distributed to colleagues. I have tried recording a macro, but this does not work, I have also looked at all the methods, objects and properties associated with the application object, but cannot find any reference to macro virus protection.  Displayalerts = false does not work for this dialog box either.

Is there a way of disabling the warning dialog by using VBA, so that my spreadsheet will execute uninterrupted?
0
Comment
Question by:AMcatear
  • 3
  • 2
  • 2
  • +4
11 Comments
 
LVL 4

Accepted Solution

by:
WolfgangKoenig earned 34 total points
ID: 6348059
I think there is no way when you only open the worksheet ...

But i have written an vb exe that opens an excel workbook (with macros) via com/ole and the macro virus warning does not to appear.

I think when you open your workbook via ole the macro virus warning message box is suppressed by Excel.

I can tell you the code you some points ;O)

WoK
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 6348222
Have you tried:
Application.DisplayAlerts = False
0
 
LVL 43

Expert Comment

by:TimCottee
ID: 6348306
If you could do this in VBA then the warning would be completely useless as a malicious macro could disable the warning and run anyway.
0
Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 5

Expert Comment

by:rkot2000
ID: 6348764
office 2000 has an utility to sing your own macros. it's should work for you ...

Basically you can create your own digital signature use it to sing macros.
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 6349621
If you have 2000, i am with rkot2000
Displaysalerts is used to ther things, not macro alerts ("The file you try to save already exist...", "doc..... not saved, do you like to close anyway....", and so on)
0
 
LVL 12

Expert Comment

by:guidway
ID: 7190528
This question appears to have been abandoned. A Moderator will be asked to
close this question after seven days, with the following recommended
disposition:

Points to TimCottee

If you have any comment or objection to the recommendation, please leave it here.

guidway
EE Cleanup Volunteer

0
 
LVL 4

Expert Comment

by:WolfgangKoenig
ID: 7190589
Why not points to mee ?

Best regards
WoK
0
 
LVL 5

Expert Comment

by:rkot2000
ID: 7190624
because my solution has two votes :))
0
 
LVL 12

Expert Comment

by:guidway
ID: 7190641
Actually, after looking over it again I think we can use a 3 way split here. All three of your answers do appear to be correct.

This question appears to have been abandoned. A Moderator will be asked to
close this question after seven days, with the following recommended
disposition:

Split points between, TimCottee, rkot2000, and WolfgangKoenig

If you have any comment or objection to the recommendation, please leave it here.

guidway
EE Cleanup Volunteer

0
 
LVL 5

Expert Comment

by:rkot2000
ID: 7190672
With WolfgangKoenig solution you need to distribute vb application with vb runtime.
0
 
LVL 5

Expert Comment

by:Netminder
ID: 7208112
Per recommendation, force-accepted.

Netminder
CS Moderator

TimCottee: points for you at http://www.experts-exchange.com/jsp/qShow.jsp?ta=visualbasic&qid=20334313
rkot2000: points for you at http://www.experts-exchange.com/jsp/qShow.jsp?ta=visualbasic&qid=20334315
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

789 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