• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 6. Explore Security in Depth >  Program with Passwords and Encryption

6.4. Program with Passwords and Encryption

You can set passwords and encryption options in code using the Workbook object's security members, such as the Password property and SetEncryptionProperties method. From a security standpoint, it doesn't make sense to hardcode passwords into Visual Basic macros. Instead, the Workbook object's security members are generally used in conjunction with User Forms to set passwords and encryption chosen by the user through a customized interface.


Note:

You can enforce strong password rules by adding code to a template's Before_Save event.



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint