Consulting

Results 1 to 14 of 14

Thread: A Custom UI code to do ...

  1. #1
    VBAX Regular
    Joined
    Dec 2012
    Location
    Kabul - Afghanistan
    Posts
    40
    Location

    Exclamation A Custom UI code to do ...

    Hi to All!
    I need a Custom UI code that can enable macros running in a PC on its own. I mean when i open my file without my permission it must enable the macros. Or A code that can enable the macro disabling.

  2. #2
    to autorun it ,

    Put it in this workbook module and put it in workbook load event

  3. #3
    VBAX Regular
    Joined
    Dec 2012
    Location
    Kabul - Afghanistan
    Posts
    40
    Location
    I don't want to autorun it. I want that windows or Microsoft Excel can't disable it by using a Custom UI code. Or another way that can do the work i want.

  4. #4
    VBAX Mentor
    Joined
    Feb 2009
    Posts
    493
    Location
    I don't think there is any code that can disable security settings. It would make the security settings useless if someone could just disable them with out user input.
    -----------------------------------------
    The more you learn about something the more you know you have much to learn.

  5. #5
    VBAX Sage
    Joined
    Apr 2007
    Location
    United States
    Posts
    8,729
    Location
    Put it in a Trusted Location (2007/2010 only)

    Paul
    Last edited by Paul_Hossler; 01-06-2013 at 11:33 AM.

  6. #6
    VBAX Guru Kenneth Hobs's Avatar
    Joined
    Nov 2005
    Location
    Tecumseh, OK
    Posts
    4,956
    Location
    Do you mean that you want macros enabled when your xlsm is opened? We have discussed this in the past. Your macro would hide all sheets but one when it closes. When it opens, it would enable all sheets. Of course VBA Project needs to be password protected.

  7. #7
    VBAX Sage
    Joined
    Apr 2007
    Location
    United States
    Posts
    8,729
    Location
    Do you mean that you want macros enabled when your xlsm is opened? We have discussed this in the past. Your macro would hide all sheets but one when it closes. When it opens, it would enable all sheets. Of course VBA Project needs to be password protected.
    I've only ever seen used to force the user to enable macros

    If the OP is looking to bypass the [Enable Macros] security prompt entirely, Trusted Locations is the only way I've ever found.

    I would like to know if there's another way

    Paul

  8. #8
    Knowledge Base Approver VBAX Wizard
    Joined
    Apr 2012
    Posts
    5,646
    If your application has any merit for the user (s)he will be eager to enable macros.....

  9. #9
    VBAX Regular
    Joined
    Dec 2012
    Location
    Kabul - Afghanistan
    Posts
    40
    Location
    Hi dears!
    I am thinking your dears mean that i add my file location in trusted Location. I am right or not. Please Help

  10. #10
    One way is that you can get your macros digitally signed. In that way it will not show security setting to load every time and the macros will be considered as trusted.

  11. #11
    VBAX Regular
    Joined
    Dec 2012
    Location
    Kabul - Afghanistan
    Posts
    40
    Location
    Dear jignesh142!
    How I can get my macros digitally signed. Please help me.

  12. #12
    Knowledge Base Approver VBAX Wizard
    Joined
    Apr 2012
    Posts
    5,646
    Use the help in the VBEditor: lemma digital signature.

  13. #13
    VBAX Master Aflatoon's Avatar
    Joined
    Sep 2009
    Location
    UK
    Posts
    1,720
    Location
    That is still no guarantee - it is perfectly possible for a user to have "Disable all macros" set.
    Be as you wish to seem

  14. #14
    Please visit the link for getting your macros digitally signed

    http://office.microsoft.com/en-in/ex...001231781.aspx

Posting Permissions

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