Getting Started
First, let's take a look at the pieces we're going to need. Aside from the obvious need for a server that will execute Active Server Pages, we will need some sort of database in which to store our user information. We'll also need some way to actually send the emails.
We can use any ODBC-compliant database, such as Access, SQL Server, or Oracle. For this project, we'll assume that you have created a System Data Source Name called mailDB. There are other ways to refer to databases, but a System DSN is generally faster and more convenient than DSN-less connections and User DSNs, respectively.
The mechanics of sending the emails can be a bit more difficult. When we want to connect to a database, we can use the Active Data Object (ADO), which is included with Active Server Pages. Unfortunately, while some Microsoft products, such as Exchange Server, come with a mail-capable object called CDONTS, no such component is included with all versions of ASP. Fortunately, we can download and use some components for free. In this case, we'll use ASPEmail, a free component from Persits Software. It can be downloaded at http://www.aspemail.com.
The component is simple to set up and use: Simply download it and run the installer, and then register the component using this command:
C:\>regsvr32 c:\AspEmailDir\AspEmail.dll