VBA Compiler and Formula Protection

I’ve been working with XLS Padlock for a few weeks now and am happy to observe that users do not seem to be able to bring up the VB editor when running the exe file; however, I’m concerned that I’m missing something because of the fact that your product contains capabilities to prevent users from viewing the VBA code and protected formulas. Are you protecting against other mechanisms for accessing the VBA code and protected formulas rather than using the VB editor and password-breaking macros? Please explain. Thanks!

XLS Padlock has special security features for VBA scripts. Instead of trying to prevent access to the VB editor, you move vital parts of your VBA code from VBE to XLS Padlock. XLS Padlock will compile these VBA lines to bytecode. Bytecode is inaccessible to end users, while it remains functional.
For instance, your original VBA macro could be:

Sub Test()
 Line 1
 Line 2
 Line 3
 Line 4
End Sub

You move vital parts (for instance, three lines of your VBA macro into XLS Padlock) and you replace your original code by:

Sub Test()
  Line 1
  Call to XLS Padlock protected macro
  Line 4
End Sub

As you can see, the user can’t guess what lines 2 and 3 are. So he can’t copy working code because it is useless without the moved parts.

You can check our user guide:

(VBA protection topic)

Or this video “How to use the VBA compiler of XLS Padlock”

And finally,
we have a working sample that uses VBA protected code:


You’ll see
that you can’t access the original VBA, while it remains functional.

Yes, thanks. I understand XLS Padlock’s capability for compiling VBA, but that doesn’t quite address my question. You used the phrase “instead of trying to prevent access to the VB editor”, and that’s really all I’m trying to understand at this point. I see that I have the ability to do things like prevent “right-clicking” and prevent “copy and paste”, and I observe that Excel’s Developer menu is not available and that I cannot seem to bring up the VB editor when my exe file is running. I want to understand whether XLS Padlock does something to prevent the VB editor from running and, if not, how would a user go about bringing it up after bringing up my exe file. Given that your product provides the capability to compile VB code as well as hide formulas, I’m assuming there is a way for a user to run the VB editor. I just don’t how that’s done and would appreciate some clarification in that area. Thanks!

We tried to hide/disable ways to access the VB editor but maybe there are some we have forgotten. That’s why it’s better to use the compiler protection which can’t be bypassed.

OK, thanks. It makes sense now.