VBA Code Compilation
Compile VBA code into secure, obfuscated 32-bit and 64-bit DLLs.
Overview
Compile your VBA macros into secure, obfuscated 32-bit and 64-bit DLLs. Your source code is transformed into compiled bytecode that cannot be decompiled back to the original VBA, protecting your intellectual property from reverse engineering.
Key Benefits
- Generates both 32-bit and 64-bit DLLs automatically
- Full VBA code obfuscation prevents reverse engineering
- Auto-generated VBA bridge module for seamless integration
- Simple VBAPL_Execute function call from your Office files
- Supports Sub, Function, and complex VBA constructs
How VBA Compilation Works
From source scripts to protected DLLs, VBA Padlock applies a secure pipeline designed to remove readable VBA while preserving full application behavior.
Parse and validate your scripts
VBA Padlock analyzes your .bas modules, checks syntax compatibility, and validates references before any build output is produced.
Generate protected bytecode
Readable VBA code is transformed into encrypted bytecode executed by the VBA Padlock runtime, not by the native VBA editor.
Build architecture-specific runtimes
The build creates both 32-bit and 64-bit runtime DLLs, so your project works transparently across Office installations.
Inject VBA Bridge wrappers
An auto-generated VBA Bridge module exposes VBAPL_Execute and related helpers to call your protected functions from Office events and UI.
Output You Can Distribute Immediately
After publishing, your Office file works with a companion bin/ folder that contains both runtimes and the compiled satellite DLL.
MyProject/
├── MyProject.xlsm
└── bin/
├── MyProjectrun32.dll
├── MyProjectrun64.dll
└── MyProject.dll
Calling Protected Functions from Office VBA
Your business logic stays hidden in the DLL, while your workbook keeps lightweight wrappers for forms, buttons, and events.
Public Sub OnClick_Calculate()
Dim result As Variant
result = VBAPL_Execute("CalculateTax", Range("A1").Value)
MsgBox "Tax Result: " & result
End Sub The bridge automatically selects the right runtime (32-bit or 64-bit), so you avoid architecture-specific VBA declarations.
What You Gain with Compilation
Full Office Object Model access from compiled code (Excel, Word, Access, PowerPoint)
Support for Sub/Function calls with parameters and return values through VBAPL_Execute
Digitally signed runtime DLLs for SmartScreen and antivirus trust
Tamper resistance via runtime + satellite integrity checks
Ready-to-ship distribution format with the required `bin/` structure
Feature documentation
Deep dive into architecture and security model.
Excel tutorial
End-to-end workflow from code to distribution.
Compile Project UI
Understand parser, diagnostics, and F5 cycle.
VBA to DLL overview
Broader explanation for prospects and evaluations.
What Is a VBA Compiler?
Why you need a VBA compiler and how it works.
Ready to Secure Your VBA Code?
Download VBA Padlock and start compiling, protecting, and licensing your VBA macros today.