+ Reply to Thread
Results 1 to 7 of 7

Privacy Warning

  1. #1
    Registered User
    Join Date
    01-30-2013
    Location
    South Carolina
    MS-Off Ver
    2010
    Posts
    10

    Question Privacy Warning

    Hello!

    I use a VBA script to format hundreds of Excel files at a time to a specific formatting standard. This works fine most of the time, but occasionally I get the annoying "Privacy Warning" popup that has to be manually clicked in order to continue. This requires a person to be present during the entire process to make sure it can continue with the formatting. I need to remove this warning so that it never pops-up.

    I can't do it individually because I get too many from different sources. My understanding is that the typical way for disabling these only does it for the workbook you are currently working in, so it has no global effect. Is there a way to disable this warning totally or to bypass it somehow?


    Any help would be greatly appreciated!

  2. #2
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Privacy Warning

    at what point do you get the warning-when saving the files?
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  3. #3
    Forum Contributor
    Join Date
    07-27-2012
    Location
    California, USA
    MS-Off Ver
    Excel 2003
    Posts
    198

    Re: Privacy Warning

    This code allowed me to supress the security warning message
    in Excel 2003. I have no other adivce to offer if you can't make
    it work in your Excel version.

    With my security level set to the 'Very High' level, I was able to open
    from a separate workbook (#1 workbook with the code below) a workbook (#2) that contains
    a macro, plus run the macro (in #2) without the warning. When opening the #2 workbook
    in a separate session, I could not run the macro due to the security level, as expected.

    What I can't explain is why the #1 workbook lets me run a macro to
    change the security level when the security level is at Very High. I assigned
    the keys Ctrl+e to run that macro (in #1).

    edit: Later testing required that I open the #1 workbook with a security level of medium or low.


    Thanks to Microsoft's MDSN website for an example of how to use
    Application.AutomationSecurity.
    Good luck.
    Please Login or Register  to view this content.
    Last edited by xLJer; 04-01-2013 at 09:45 PM.

  4. #4
    Registered User
    Join Date
    01-30-2013
    Location
    South Carolina
    MS-Off Ver
    2010
    Posts
    10

    Re: Privacy Warning

    Quote Originally Posted by JosephP View Post
    at what point do you get the warning-when saving the files?
    Yes, right when it gets to the point where it saves the Workbook and then is supposed to go on to the next one. Instead, I get a "Privacy Warning: This document contains macros, ActiveX controls, XML expansion pack information, or Web components."

    XLJer - I'm not quite sure how to implement that. I am by no means an expert at this. It's not the workbook with the macro that I am running from that is the issue, it's all of the workbooks that are being opened, formatted, and saved. Some of those have some kind of security setting (I assume) that makes the warning come up. Do you think this could be added to the formatting code I have already so that each workbook that is opened and formatted is opened (and saved) with a "Low Security" level?

  5. #5
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Privacy Warning

    you can't turn it off globally but your code can turn it off for any workbook it is processing by setting the removepersonalinformation property of the workbook to false

  6. #6
    Registered User
    Join Date
    01-30-2013
    Location
    South Carolina
    MS-Off Ver
    2010
    Posts
    10

    Re: Privacy Warning

    Quote Originally Posted by JosephP View Post
    you can't turn it off globally but your code can turn it off for any workbook it is processing by setting the removepersonalinformation property of the workbook to false

    This worked perfectly! I just added on a .RemovePersonalInformation = False before the .Save and now I'm no longer bothered by pesky warnings.

    Thank you!

  7. #7
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Privacy Warning

    you're welcome :-)

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1