GetCustomListContents Method
Applies To
Application object.
Description
Returns a custom list (an array of strings).
Syntax
expression.GetCustomListContents(ListNum)
expression Required. An expression that returns an Application object.
ListNum Required Long. The list number.
See Also
AddCustomList method, CustomListCount property, DeleteCustomList method, GetCustomListNum method.
Example
This example writes the elements of the first custom list in column one on Sheet1.
listArray = Application.GetCustomListContents(1)
For i = LBound(listArray, 1) To UBound(listArray, 1)
Worksheets("Sheet1").Cells(i, 1).Value = listArray(i)
Next i