PDA

View Full Version : Solved: Disable security warnings in Access, enable macros



Gingertrees
08-05-2008, 10:24 AM
Hello. I have an Access database running VBA, so I have the security set at Medium. I think that's important b/c users at my company can DL whatever they want, and this provides at least a small barrier to infecting their computers.

Anyway, FOR THIS DB ONLY, how can I disable the security warnings:
1) Unsafe expressions are not blocked. Do you want to block unsafe expressions?
[User presses "No"]
followed by
2) This file may not be safe if it contains code that was intended to harm your computer. Do you want to open the file or cancel the operation?
[User presses [Open]

???
Thanks.

CreganTur
08-05-2008, 11:04 AM
I'm pretty sure that there's no way to override the security settings via VBA... since that would completely negate the reason for the security settings.

The only way to get rid of the macro warning is to set the security level to Low, but this as an Access setting independant from any singular .mdb file.



Understanding the Security Warning

Access databases can run Visual Basic program code, which could be used by a malicious person to harm your computer. When you open any Access database?including the practice files for this book?you'll see the following safety warning:
http://images.books24x7.com/bookimages/id_21298/fig564_01.jpg (http://javascript<b></b>:PopImage('IMG_721','http://images.books24x7.com/bookimages/id_21298/fig564_01_0.jpg','467','251'))
If you know the database is from a safe source, you can click Open without concern. If you click Cancel, Access doesn't open the database.
This warning can become tiresome. If you want to prevent the warning from appearing when you open a database, you can disable it. If you do, be sure never to accept an Access database from an untrustworthy source.
Be Sure To start Access before carrying out these steps.

To disable the Access security warning:

On the Tools menu, click Macro and then Security.
On the Security tab, select the Low option, and click OK.
If Access asks whether you want to allow unsafe expressions, click NoAs you can see from the above, the only caveat to using Low security settings is ensuring that you never accept a database from an untrustworthy source :wot... not very helpful security guidelines, huh?

Gingertrees
08-05-2008, 11:34 AM
Oh well. Just have to keep telling everyone " 'press yes' and 'open' BUT ONLY FOR THIS DATABASE!" Thanks anyway.