Microsoft provides programming examples for illustration only, without warranty either expressed or implied, including, but not limited to, the implied warranties of merchantability and/or fitness for a particular purpose. This article assumes that you are familiar with the programming language being demonstrated and the tools used to create and debug procedures. Microsoft support professionals can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific needs.
If you have limited programming experience, you may want to contact a Microsoft Certified Partner or Microsoft Advisory Services. For more information, visit these Microsoft Web sites:
Microsoft Certified Partners -
https://partner.microsoft.com/global/30000104Microsoft Advisory Services -
http://support.microsoft.com/gp/advisoryserviceFor more information about the support options that are available and about how to contact Microsoft, visit the following Microsoft Web site:
http://support.microsoft.com/default.aspx?scid=fh;EN-US;CNTACTMS To create and run the sample macro, follow these
steps:
- Create a new Microsoft Excel workbook, and in column A of
Sheet1, type a list that contains 50 entries (that is, type data in the range
A1:A50).
- Press ALT+F11 to start the Visual Basic Editor.
- Click Module on the Insert menu.
- Type the following sample code into the module:
Sub Custom_List()
Application.AddCustomList _
ListArray:=Sheets("Sheet1").Range("A1:A50")
End Sub
- Run the macro.
- On the Tools menu in Excel 2000, click Options.
- Select the Custom Lists tab. In the Custom Lists box, click the custom list that you created (located at the
bottom of the list).
In the List entries box, you
can view the custom list from Sheet1, range A1:A50.
To share this custom list with other users, name the macro Sub
Auto_Open(). The choice of this name causes the macro to run as soon as the
file is opened and programmatically distributes the workbook. If you name the
macro something other than Sub Auto_Open, you need to then distribute the
workbook and advise users to run the macro when they receive the file.