Visual Basic for Applications (VBA) is a variant of the now obsolete Visual Basic 6. VBA was commonly used as a programming language within the Microsoft Office family of products, and it was also available to third-party developers as a bolt-on scripting language for incorporation into third-party applications. VBA itself is now obsolete, but its use within Microsoft Office means that it is likely to be used by ZEMAX users for many years to come.

This article describes how to transfer data to and from ZEMAX using Microsoft Excel as the example VBA program. The code is provided and a simple 'hello world' demonstration is given, along with details of some specific issues when using Excel.