If you’re familiar with array formulas, you’ll be happy to know that you can create VBA functions that return an array. Returning an array of month names. Let’s start out with a simple example. The MonthNames function returns a 12-element array of — you guessed it — month names.